<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 19, 2015 at 1:09 PM, Dehao Chen <span dir="ltr"><<a href="mailto:dehao@google.com" target="_blank">dehao@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">disable-llvm-optzns does not help:<br>
<br>
/ssd/llvm_trunk/build.gccopt/./bin/clang -cc1 -internal-isystem<br>
/ssd/llvm_trunk/build.gccopt/bin/../lib/clang/3.8.0/include<br>
-nostdsysteminc -dwarf-version=4 -debug-info-kind=line-tables-only<br>
-disable-llvm-optzns  -emit-llvm <<br>
/ssd/llvm_trunk/tools/clang/test/CodeGen/debug-info-scope.c<br>
<br>
This still emits discriminators.<br></blockquote><div><br></div><div>Do you know where the discriminators are coming from in this case? Does the frontend add some of them (in which case the test case shouldn't need updating for your recent backend change still, hopefully)? Is there some other codepath that is running the AddDiscriminator transformation?<br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5"><br>
On Thu, Nov 19, 2015 at 12:46 PM, David Blaikie <<a href="mailto:dblaikie@gmail.com">dblaikie@gmail.com</a>> wrote:<br>
><br>
><br>
> On Thu, Nov 19, 2015 at 12:42 PM, Dehao Chen <<a href="mailto:dehao@google.com">dehao@google.com</a>> wrote:<br>
>><br>
>> Yes, as discriminator is a backend pass, it should *not* affect frontend<br>
>> tests.<br>
><br>
><br>
> Could you update these tests to not involve discriminators by passing<br>
> -disable-llvm-optzns instead?<br>
><br>
>><br>
>><br>
>> On Thu, Nov 19, 2015 at 12:36 PM, David Blaikie <<a href="mailto:dblaikie@gmail.com">dblaikie@gmail.com</a>><br>
>> wrote:<br>
>> ><br>
>> ><br>
>> > On Thu, Nov 19, 2015 at 11:53 AM, Dehao Chen via cfe-commits<br>
>> > <<a href="mailto:cfe-commits@lists.llvm.org">cfe-commits@lists.llvm.org</a>> wrote:<br>
>> >><br>
>> >> Author: dehao<br>
>> >> Date: Thu Nov 19 13:53:16 2015<br>
>> >> New Revision: 253595<br>
>> >><br>
>> >> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=253595&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=253595&view=rev</a><br>
>> >> Log:<br>
>> >> Update clang tests to accomendate discriminator changes.<br>
>> >><br>
>> >> Summary: The discriminator change in <a href="http://reviews.llvm.org/D14738" rel="noreferrer" target="_blank">http://reviews.llvm.org/D14738</a><br>
>> >> will<br>
>> >> fail these clang tests. Update the test to accomendate the<br>
>> >> discriminator<br>
>> >> change.<br>
>> ><br>
>> ><br>
>> > Do these tests need to be testing discriminators in the frontend? Could<br>
>> > we<br>
>> > just -mllvm -disable-llvm-optzns on these tests? (can the functionality<br>
>> > be<br>
>> > wholely tested in LLVM, I assume so if it's phrased as an LLVM<br>
>> > transformation pass?)<br>
>> ><br>
>> >><br>
>> >><br>
>> >> Reviewers: dblaikie, davidxl, dnovillo<br>
>> >><br>
>> >> Differential Revision: <a href="http://reviews.llvm.org/D14836" rel="noreferrer" target="_blank">http://reviews.llvm.org/D14836</a><br>
>> >><br>
>> >> Modified:<br>
>> >>     cfe/trunk/test/CodeGen/debug-info-scope.c<br>
>> >>     cfe/trunk/test/CodeGenObjC/arc-linetable.m<br>
>> >><br>
>> >> Modified: cfe/trunk/test/CodeGen/debug-info-scope.c<br>
>> >> URL:<br>
>> >><br>
>> >> <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/debug-info-scope.c?rev=253595&r1=253594&r2=253595&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/debug-info-scope.c?rev=253595&r1=253594&r2=253595&view=diff</a><br>
>> >><br>
>> >><br>
>> >> ==============================================================================<br>
>> >> --- cfe/trunk/test/CodeGen/debug-info-scope.c (original)<br>
>> >> +++ cfe/trunk/test/CodeGen/debug-info-scope.c Thu Nov 19 13:53:16 2015<br>
>> >> @@ -10,6 +10,7 @@ int main() {<br>
>> >><br>
>> >>  // GMLT-NOT: !DILexicalBlock<br>
>> >>  // GMLT: !DILexicalBlockFile({{.*}}, discriminator: 1)<br>
>> >> +// GMLT: !DILexicalBlockFile({{.*}}, discriminator: 2)<br>
>> >>  // Make sure we don't have any more lexical blocks because we don't<br>
>> >> need<br>
>> >> them in<br>
>> >>  // -gmlt.<br>
>> >>  // GMLT-NOT: !DILexicalBlock<br>
>> >><br>
>> >> Modified: cfe/trunk/test/CodeGenObjC/arc-linetable.m<br>
>> >> URL:<br>
>> >><br>
>> >> <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGenObjC/arc-linetable.m?rev=253595&r1=253594&r2=253595&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGenObjC/arc-linetable.m?rev=253595&r1=253594&r2=253595&view=diff</a><br>
>> >><br>
>> >><br>
>> >> ==============================================================================<br>
>> >> --- cfe/trunk/test/CodeGenObjC/arc-linetable.m (original)<br>
>> >> +++ cfe/trunk/test/CodeGenObjC/arc-linetable.m Thu Nov 19 13:53:16 2015<br>
>> >> @@ -34,9 +34,9 @@<br>
>> >><br>
>> >>  // CHECK: define {{.*}}testCleanupVoid<br>
>> >>  // CHECK: icmp ne {{.*}}!dbg ![[SKIP1:[0-9]+]]<br>
>> >> -// CHECK: store i32 0, i32* {{.*}}, !dbg ![[RET8:[0-9]+]]<br>
>> >> +// CHECK: store i32 0, i32* {{.*}}, !dbg ![[STORE8:[0-9]+]]<br>
>> >>  // CHECK: @objc_storeStrong{{.*}}, !dbg ![[ARC8:[0-9]+]]<br>
>> >> -// CHECK: ret {{.*}} !dbg ![[RET8]]<br>
>> >> +// CHECK: ret {{.*}} !dbg ![[RET8:[0-9]+]]<br>
>> >><br>
>> >>  typedef signed char BOOL;<br>
>> >><br>
>> >> @@ -112,8 +112,9 @@ typedef signed char BOOL;<br>
>> >>        [delegate testVoid :s];<br>
>> >>      }<br>
>> >>    }<br>
>> >> -  // CHECK: ![[RET8]] = !DILocation(line: [[@LINE+2]], scope:<br>
>> >> -  // CHECK: ![[ARC8]] = !DILocation(line: [[@LINE+1]], scope:<br>
>> >> +  // CHECK: ![[STORE8]] = !DILocation(line: [[@LINE+3]], scope:<br>
>> >> +  // CHECK: ![[ARC8]] = !DILocation(line: [[@LINE+2]], scope:<br>
>> >> +  // CHECK: ![[RET8]] = !DILocation(line: [[@LINE+1]], scope:<br>
>> >>  }<br>
>> >><br>
>> >><br>
>> >><br>
>> >><br>
>> >> _______________________________________________<br>
>> >> cfe-commits mailing list<br>
>> >> <a href="mailto:cfe-commits@lists.llvm.org">cfe-commits@lists.llvm.org</a><br>
>> >> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits</a><br>
>> ><br>
>> ><br>
><br>
><br>
</div></div></blockquote></div><br></div></div>