Bug 136765 - Move ASan flag settings from DebugRelease.xcconfig to Base.xcconfig
Summary: Move ASan flag settings from DebugRelease.xcconfig to Base.xcconfig
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: David Farler
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-09-11 16:22 PDT by David Farler
Modified: 2015-01-28 11:09 PST (History)
9 users (show)

See Also:


Attachments
This patch moves all of the ASan environment variables (24.33 KB, patch)
2015-01-26 21:04 PST, Dana Burkart
no flags Details | Formatted Diff | Diff
Fix style issue (24.30 KB, patch)
2015-01-26 21:12 PST, Dana Burkart
darin: review+
ap: commit-queue-
Details | Formatted Diff | Diff
Address concerns (24.17 KB, patch)
2015-01-27 16:38 PST, Dana Burkart
ap: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Farler 2014-09-11 16:22:50 PDT
Production-style builds aren't picking up ASan flags even though the ASan xcconfig is passed at the command line. We need to move those settings up to Base.xcconfig wherever it occurs in DebugRelease.xcconfig.
Comment 1 Alexey Proskuryakov 2015-01-20 11:14:08 PST
Dana, isn't this why ASan roots build incorrectly?
Comment 2 Dana Burkart 2015-01-20 12:39:37 PST
(In reply to comment #1)
> Dana, isn't this why ASan roots build incorrectly?

Could be. I will test this theory out.
Comment 3 Radar WebKit Bug Importer 2015-01-26 20:02:17 PST
<rdar://problem/19610008>
Comment 4 Dana Burkart 2015-01-26 21:04:41 PST
Created attachment 245411 [details]
This patch moves all of the ASan environment variables
Comment 5 WebKit Commit Bot 2015-01-26 21:06:10 PST
Note that there are important steps to take when updating ANGLE. See http://trac.webkit.org/wiki/UpdatingANGLE
Comment 6 WebKit Commit Bot 2015-01-26 21:06:21 PST
Attachment 245411 [details] did not pass style-queue:


ERROR: Source/WebCore/ChangeLog:8:  You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible.  [changelog/nonewtests] [5]
Total errors found: 1 in 24 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 7 Dana Burkart 2015-01-26 21:12:22 PST
Created attachment 245412 [details]
Fix style issue
Comment 8 Darin Adler 2015-01-26 21:43:31 PST
Comment on attachment 245412 [details]
Fix style issue

Why do some of these also include $(inherited) but others don’t?
Comment 9 Alexey Proskuryakov 2015-01-27 00:11:02 PST
Comment on attachment 245412 [details]
Fix style issue

View in context: https://bugs.webkit.org/attachment.cgi?id=245412&action=review

This breaks the build: "recursive template instantiation exceeded maximum depth".

That's caused by losing this option from DebugRelease.xcconfig in TestWebKitAPI:

OTHER_CPLUSPLUSFLAGS = -ftemplate-depth=256 $(ASAN_OTHER_CPLUSPLUSFLAGS);

Grepping for OTHER_ in WebKit, I noticed that DumpRenderTree.xcodeproj overrides some of these flags to empty in its "All" target. Is this just accidental noise? Can it be deleted?

> Source/WebCore/WebCore.xcodeproj/project.pbxproj:30365
> -				OTHER_LDFLAGS = "";
> +				OTHER_LDFLAGS = "$(ASAN_OTHER_LDFLAGS)";

The WebCoreExportFileGenerator target configuration looks super weird. We should probably give it its own xcconfig file, rather than use WebCore.xcconfig and then override its values.
Comment 10 Dana Burkart 2015-01-27 10:31:52 PST
(In reply to comment #8)
> Comment on attachment 245412 [details]
> Fix style issue
> 
> Why do some of these also include $(inherited) but others don’t?

I'm not sure. All of the projects with DebugRelease.xcconfigs which had $(inherited) don't set the environment variables anywhere else, so I guess they were there just to be safe?
Comment 11 Dana Burkart 2015-01-27 10:36:57 PST
(In reply to comment #9)
> Comment on attachment 245412 [details]
> Fix style issue
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=245412&action=review
> 
> This breaks the build: "recursive template instantiation exceeded maximum
> depth".
> 
> That's caused by losing this option from DebugRelease.xcconfig in
> TestWebKitAPI:
> 
> OTHER_CPLUSPLUSFLAGS = -ftemplate-depth=256 $(ASAN_OTHER_CPLUSPLUSFLAGS);
> 

Okay, I'll put that back in.

> Grepping for OTHER_ in WebKit, I noticed that DumpRenderTree.xcodeproj
> overrides some of these flags to empty in its "All" target. Is this just
> accidental noise? Can it be deleted?

I think so. I'll give it a shot.

> 
> > Source/WebCore/WebCore.xcodeproj/project.pbxproj:30365
> > -				OTHER_LDFLAGS = "";
> > +				OTHER_LDFLAGS = "$(ASAN_OTHER_LDFLAGS)";
> 
> The WebCoreExportFileGenerator target configuration looks super weird. We
> should probably give it its own xcconfig file, rather than use
> WebCore.xcconfig and then override its values.

The other targets in WebCore set it to $(ASAN_OTHER_LDFLAGS) instead of being empty, so I simply changed it to match...
Comment 12 Alexey Proskuryakov 2015-01-27 11:05:21 PST
> The other targets in WebCore set it to $(ASAN_OTHER_LDFLAGS) instead of being empty, so I simply changed it to match...

Right, I don't think that factoring out an xcconfig for this target should be part of this patch.
Comment 13 Dana Burkart 2015-01-27 16:38:41 PST
Created attachment 245493 [details]
Address concerns
Comment 14 Dana Burkart 2015-01-28 10:28:38 PST
Committed revision 179269.