New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 741336 link

Starred by 2 users

Issue metadata

Status: Archived
Owner:
Closed: Jul 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug



Sign in to add a comment

Incorrect log_path specified in ASAN_OPTION for non-platform2 packages

Project Member Reported by benchan@chromium.org, Jul 12 2017

Issue description

https://chromium-review.googlesource.com/c/213895/ stripped SYSROOT prefix from 'log_path' specified in ASAN_OPTIONS. That only works for platform2 unit tests, which chroots into SYSROOT before running the tests. Non-platform2 packages (e.g. those in portage-stable / chromiumos-overlay) don't seem to chroot into SYSROOT before running tests, so ASAN fails to write logs to the log_path without the SYSROOT prefix.
 

Comment 1 by vapier@chromium.org, Jul 12 2017

this is true, but the ability to safely run unittests outside of the sysroot is extremely fragile and relies more on luck.  i don't have a suggestion for how to make those unittests run inside the sysroot short of running each one by hand through the platform2 runner.

Comment 2 by vapier@chromium.org, Jul 12 2017

maybe as a stop gap, we can have the code only mung the path when $PLATFORM_GYP_FILE is defined.  i think all of our sysroot-based unittests are going through the platform eclass atm.
sgtm, this stop gap solution at least allows us to see the asan failures more easily on amd64-generic-asan.

I'm testing https://chromium-review.googlesource.com/c/568913/
Cc: -benchan@chromium.org
Owner: benchan@chromium.org
Status: Started (was: Untriaged)
Project Member

Comment 5 by bugdroid1@chromium.org, Jul 13 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/b27c34c08b75e02b0c298e9b66f4b8fbebd63473

commit b27c34c08b75e02b0c298e9b66f4b8fbebd63473
Author: Ben Chan <benchan@chromium.org>
Date: Thu Jul 13 18:44:44 2017

Strip SYSROOT prefix from ASAN log path only for platform_test targets.

CL:213895 stripped the SYSROOT prefix from the 'log_path' option
specified in $ASAN_OPTIONS, but that only works for unit tests launched
by platform_test as platform_test chroots into SYSROOT before running
the unit tests. For other non-platform2 packages, we need to include
SYSROOT in the ASAN log path. Similarly, the 'suppressions' option
specified in $LSAN_OPTIONS requires similar handling.

BUG= chromium:741336 
TEST=Tested the following with both platform2 and non-platform2 targets:
- Verify that ASAN can output logs to the path specified in
  $ASAN_OPTIONS.
- Verify that LSAN can load suppressions from the path specified in
  $LSAN_OPTIONS.

Change-Id: I5c5bdb07c865f2608ac1efb24f1a4917799b47e2
Reviewed-on: https://chromium-review.googlesource.com/568913
Commit-Ready: Ben Chan <benchan@chromium.org>
Tested-by: Ben Chan <benchan@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/b27c34c08b75e02b0c298e9b66f4b8fbebd63473/profiles/base/profile.bashrc

Status: Fixed (was: Started)

Comment 7 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment