Page MenuHomePhabricator

leonardchan (Leonard Chan)
User

Projects

User does not belong to any projects.

User Details

User Since
Apr 25 2018, 1:47 PM (73 w, 4 d)

Recent Activity

Mon, Sep 16

leonardchan added inline comments to rG5e37d7f9ff25: Implement std::condition_variable via pthread_cond_clockwait() where available.
Mon, Sep 16, 2:27 PM

Fri, Sep 13

leonardchan added a comment to D67287: [Diagnostics] Add -Wsizeof-array-div.

Not sure if we're still mentioning false positives here, but if we have something like a multidimensional array of a specific type and we want to find the number of elements inside it, this warning would also appear:

Fri, Sep 13, 3:07 PM · Restricted Project

Wed, Sep 11

leonardchan added a comment to rG81196a595c68: LiveIntervals: Split live intervals on multiple dead defs.

Hi! I think this patch is causing a test failure for DebugInfo/X86/live-debug-vars-discard-invalid.mir on our bots:

Wed, Sep 11, 11:56 AM

Tue, Sep 10

leonardchan added a comment to D67195: Adding support for overriding LLVM_ENABLE_RUNTIMES for runtimes builds..

You can see the bot at: https://luci-milo.appspot.com/p/fuchsia/builders/ci/clang-x64-linux/b8902661942095266432

Tue, Sep 10, 5:33 PM · Restricted Project
leonardchan added a comment to D67195: Adding support for overriding LLVM_ENABLE_RUNTIMES for runtimes builds..

Hi. I think this might be causing some linker failures on our x64 bots:

Tue, Sep 10, 5:23 PM · Restricted Project

Sun, Sep 8

leonardchan committed rG486b173cfeb5: [NewPM][Sancov] Create the Sancov Pass after building the pipelines (authored by leonardchan).
[NewPM][Sancov] Create the Sancov Pass after building the pipelines
Sun, Sep 8, 12:35 AM
leonardchan added a comment to D67262: [git-llvm] Do not reinvent `@{upstream}`.

Hi! I think this might've broken the normal workflow for using this helper script shown in https://llvm.org/docs/GettingStarted.html#for-developers-to-commit-changes-from-git

Sun, Sep 8, 12:35 AM · Restricted Project
leonardchan committed rL371326: [NewPM][Sancov] Create the Sancov Pass after building the pipelines.
[NewPM][Sancov] Create the Sancov Pass after building the pipelines
Sun, Sep 8, 12:29 AM
leonardchan closed D67323: [NewPM][Sancov] Create the Sancov Pass after building the pipelines.
Sun, Sep 8, 12:29 AM · Restricted Project, Restricted Project, Restricted Project

Sat, Sep 7

leonardchan created D67323: [NewPM][Sancov] Create the Sancov Pass after building the pipelines.
Sat, Sep 7, 7:25 PM · Restricted Project, Restricted Project, Restricted Project

Fri, Sep 6

leonardchan added inline comments to D67253: clang-misexpect: a standalone tool for verifying the use of __builtin_expect with PGO data.
Fri, Sep 6, 11:11 AM · Restricted Project, Restricted Project
leonardchan accepted D57836: [Intrinsic] Unsigned Fixed Point Saturation Multiplication Intrinsic.

LGTM. Thanks for taking over this!

Fri, Sep 6, 11:05 AM · Restricted Project

Wed, Sep 4

leonardchan committed rGeca01b031d44: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes (authored by leonardchan).
[NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes
Wed, Sep 4, 1:37 PM
leonardchan committed rL370971: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes.
[NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes
Wed, Sep 4, 1:30 PM
leonardchan closed D66988: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes.
Wed, Sep 4, 1:30 PM · Restricted Project, Restricted Project, Restricted Project

Tue, Sep 3

leonardchan added a comment to D59754: [Sema] Add c++2a designated initializer warnings.

Hi! We've noticed that for our arm bots, we're getting some flaky builds that sometimes fail with error: array designators are a C99 extension [-Werror,-Wc99-designator] and sometimes don't fail. 2 questions:

Tue, Sep 3, 12:09 PM · Restricted Project, Restricted Project
leonardchan added a comment to D66988: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes.

*ping*

Tue, Sep 3, 11:12 AM · Restricted Project, Restricted Project, Restricted Project

Fri, Aug 30

leonardchan added a comment to D66988: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes.

*ping* This patch also seems to fix an issue with mismatched PC table and inline counters:

Fri, Aug 30, 2:27 PM · Restricted Project, Restricted Project, Restricted Project
leonardchan added a comment to D66181: [AArch64][GlobalISel] Add support for narrowScalar of G_ZEXT.

Hi! After running a bisect, I believe this patch is causing the assertion error in https://bugs.llvm.org/show_bug.cgi?id=43171. Could you look into this? There is a reproducer attached to the bug.

Fri, Aug 30, 11:34 AM · Restricted Project

Thu, Aug 29

leonardchan accepted D66324: clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM.

Sorry about that. Still LGTM.

Thu, Aug 29, 8:23 PM · Restricted Project, Restricted Project
leonardchan accepted D66324: clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM.
Thu, Aug 29, 7:34 PM · Restricted Project, Restricted Project
leonardchan created D66988: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes.
Thu, Aug 29, 6:19 PM · Restricted Project, Restricted Project, Restricted Project

Tue, Aug 27

leonardchan added a comment to rG1299945b8128: Change the X86 datalayout to add three address spaces for 32 bit signed, 32 bit….

Hi! I'm seeing a test failure on our bots that I think may originate from this patch:

Tue, Aug 27, 3:22 PM

Aug 22 2019

leonardchan accepted D66622: [Bugfix] fix r369705 unit test.
Aug 22 2019, 3:50 PM · Restricted Project, Restricted Project
leonardchan added a comment to D66492: [Clang][CodeGen] set alias linkage on QualType.

I think this patch might be causing some test failures on our mac bots:

Aug 22 2019, 3:25 PM · Restricted Project, Restricted Project
leonardchan added a comment to D57836: [Intrinsic] Unsigned Fixed Point Saturation Multiplication Intrinsic.

I'll try to finish the work on this patch (hence the commandeer action). I hope @leonardchan won't mind that.

Aug 22 2019, 1:42 PM · Restricted Project

Aug 21 2019

leonardchan committed rG19ec31d1a5f5: [LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new… (authored by leonardchan).
[LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new…
Aug 21 2019, 10:25 AM
leonardchan committed rL369550: [LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new….
[LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new…
Aug 21 2019, 10:24 AM
leonardchan closed D66488: [LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new pass manager.
Aug 21 2019, 10:24 AM · Restricted Project, Restricted Project

Aug 20 2019

leonardchan accepted D66503: [Sanitizer] Remove unused functions.

Thanks for taking care of this! Sorry for not doing this earlier. Got caught up in other stuff.

Aug 20 2019, 3:53 PM · Restricted Project
leonardchan committed rGb0a7544ee2e3: [NewPM] Run ubsan-coroutines test under the legacy pass manager only (authored by leonardchan).
[NewPM] Run ubsan-coroutines test under the legacy pass manager only
Aug 20 2019, 1:57 PM
leonardchan committed rL369442: [NewPM] Run ubsan-coroutines test under the legacy pass manager only.
[NewPM] Run ubsan-coroutines test under the legacy pass manager only
Aug 20 2019, 1:55 PM
leonardchan closed D66493: [NewPM] Run ubsan-coroutines test under the legacy pass manager only.
Aug 20 2019, 1:55 PM · Restricted Project, Restricted Project
leonardchan added a comment to D44672: [CodeGen] Disable UBSan for coroutine functions.
In D44672#1637984, @vsk wrote:

It seems that this test leads to an UNREACHABLE under the new pass manager (can check this by adding -fexperimental-new-pass-manager to the test. I think this is because the passes for lowering the llvm.coro intrinsics are not yet ported to the new PM. Would it be fine to add -fno-experimental-new-pass-manager to the test to indicate it should be run under the legacy PM only? Thanks.

Sounds reasonable to me. It would be great to include a link to some master PR for the new PM porting effort with the test change.

Aug 20 2019, 1:37 PM · Restricted Project, Restricted Project
leonardchan created D66493: [NewPM] Run ubsan-coroutines test under the legacy pass manager only.
Aug 20 2019, 1:37 PM · Restricted Project, Restricted Project
leonardchan added a comment to D66490: [NewPM] Enable the New Pass Manager by Default in Clang.

As of now, from running check-llvm and check-clang there's 2 failing tests, but I'm trying to get those addressed.

Aug 20 2019, 12:13 PM · Restricted Project
leonardchan created D66490: [NewPM] Enable the New Pass Manager by Default in Clang.
Aug 20 2019, 12:11 PM · Restricted Project
leonardchan added a comment to D44672: [CodeGen] Disable UBSan for coroutine functions.

It seems that this test leads to an UNREACHABLE under the new pass manager (can check this by adding -fexperimental-new-pass-manager to the test. I think this is because the passes for lowering the llvm.coro intrinsics are not yet ported to the new PM. Would it be fine to add -fno-experimental-new-pass-manager to the test to indicate it should be run under the legacy PM only? Thanks.

Aug 20 2019, 12:02 PM · Restricted Project, Restricted Project
leonardchan created D66488: [LTO] Always mark regular LTO units with EnableSplitLTOUnit=1 under the new pass manager.
Aug 20 2019, 11:34 AM · Restricted Project, Restricted Project

Aug 19 2019

leonardchan added a comment to D65653: [AArch64] Change location of frame-record within callee-save area..

Could you temporarily revert this in the meantime? This is blocking our clang roll that we need to fix another Clang issue we're hitting.

Aug 19 2019, 10:49 PM · Restricted Project
leonardchan added a comment to D65653: [AArch64] Change location of frame-record within callee-save area..

Hi again. After some bisecting, we found that the relanding of this (rGf28e1128d9e) was causing a segfault on our aarch64 asan bots.

Aug 19 2019, 5:51 PM · Restricted Project

Aug 16 2019

leonardchan added a comment to rL369150: [TSan] Don't guard #include <xpc/xpc.h>.

I think this is causing this error on our mac builders:

Aug 16 2019, 3:43 PM
leonardchan added a comment to D66055: [X86] Support -mlong-double-80.

I believe this patch is causing 2 test failures on our x64 clang bots:

Aug 16 2019, 3:42 PM · Restricted Project
leonardchan added a comment to D66337: [AArch64InstrInfo] Stop getInstSizeInBytes returning non-zero for meta instructions..

This test seems to be failing on our mac builders:

Aug 16 2019, 9:41 AM · Restricted Project

Aug 15 2019

leonardchan added a comment to D65653: [AArch64] Change location of frame-record within callee-save area..

I have a suspicion that this might be causing the assertion error we see in https://bugs.llvm.org/show_bug.cgi?id=43015. Checking this now. Just wanted to raise awareness in the meantime.

Aug 15 2019, 5:37 PM · Restricted Project
leonardchan added a comment to D66189: [GWP-ASan] Implement stack frame compression..

Let me know if there's anything that you need from me to help diagnose this.

Aug 15 2019, 4:09 PM · Restricted Project, Restricted Project
leonardchan added a comment to D66189: [GWP-ASan] Implement stack frame compression..

Hi. We believe this patch is causing a CMake error for out toolchian build:

-- Compiler-RT supported architectures: i386
CMake Error at /b/s/w/ir/k/llvm-project/compiler-rt/lib/gwp_asan/CMakeLists.txt:111 (target_link_options):
  Unknown CMake command "target_link_options".

Could you look into this? Thanks.

Hey Leonard, that should have been fixed in rL369051. Can you apply that patch and let me know?

Aug 15 2019, 4:09 PM · Restricted Project, Restricted Project
leonardchan added a comment to D66189: [GWP-ASan] Implement stack frame compression..

Hi. We believe this patch is causing a CMake error for out toolchian build:

Aug 15 2019, 4:00 PM · Restricted Project, Restricted Project

Aug 12 2019

leonardchan added a comment to D64256: Teach some warnings to respect gsl::Pointer and gsl::Owner attributes.

Hi. I noticed in our builders that both of the warnings introduced in this patch are being diagnosed for pointers that don't use GSL at all. I'm attempting to make a small reproducer now.

Hi!

Clang now apply GSL annotations for some STL types automatically. So this is the expected behavior. Are any of those warnings unwanted/false positive with the newest Clang version? If so, please share the reproducers and I will either fix them ASAP or revert/turn off the warnings.

Thanks! I didn't know that they were applied to stl types. This could explain why the warning is raised in my case (std::string), but I don't think there's anything wrong in this example that would lead to a warning:

leonardchan@cp-snakewater:~/llvm-monorepo/llvm-build-3-master$ cat ~/misc/test.cpp
#include <string>

std::string MakeStr();
void other_func(const char *s);

void func(std::string s) {
  const char *x = MakeStr().c_str();
  other_func(x);
}
leonardchan@cp-snakewater:~/llvm-monorepo/llvm-build-3-master$ ~/llvm-monorepo/llvm-build-3-master/bin/clang++ -c ~/misc/test.cpp
/usr/local/google/home/leonardchan/misc/test.cpp:7:19: warning: object backing the pointer will be destroyed at the end of the full-expression [-Wdangling]
  const char *x = MakeStr().c_str();
                  ^~~~~~~~~
1 warning generated.

This was made using a release build from ToT clang.

Thanks for the repro! I think this is a true positive. MakeStr will create a temporary object, and c_str() will create a pointer that points into the buffer owned by the temporary object. At the end of the full expression the temporary object is destroyed and the result of c_str will dangle.

Aug 12 2019, 5:31 PM · Restricted Project, Restricted Project
leonardchan added a comment to D64256: Teach some warnings to respect gsl::Pointer and gsl::Owner attributes.

Hi. I noticed in our builders that both of the warnings introduced in this patch are being diagnosed for pointers that don't use GSL at all. I'm attempting to make a small reproducer now.

Hi!

Clang now apply GSL annotations for some STL types automatically. So this is the expected behavior. Are any of those warnings unwanted/false positive with the newest Clang version? If so, please share the reproducers and I will either fix them ASAP or revert/turn off the warnings.

Aug 12 2019, 4:40 PM · Restricted Project, Restricted Project
leonardchan added a comment to D64256: Teach some warnings to respect gsl::Pointer and gsl::Owner attributes.

Hi. I noticed in our builders that both of the warnings introduced in this patch are being diagnosed for pointers that don't use GSL at all. I'm attempting to make a small reproducer now.

Aug 12 2019, 3:04 PM · Restricted Project, Restricted Project

Jul 31 2019

leonardchan added a comment to D65490: [SimplifyCFG] Mark missed Changed to true..

*ping* We would like to bump up the priority of this since this allows us to enable the new PM when building fuchsia.

Jul 31 2019, 5:46 PM · Restricted Project

Jul 30 2019

leonardchan accepted D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings.

LGTM but I'd wait a day to see if anyone else has comments they'd like to add before landing.

Jul 30 2019, 7:48 PM · Restricted Project

Jul 29 2019

leonardchan abandoned D63174: [clang][NewPM] Add RUNS for tests that produce slightly different IR under new PM.

Replaced with D65110

Jul 29 2019, 12:16 PM · Restricted Project

Jul 26 2019

leonardchan committed rG01ba91e6af76: [NewPM] Run avx*-builtins.c tests under the new pass manager only (authored by leonardchan).
[NewPM] Run avx*-builtins.c tests under the new pass manager only
Jul 26 2019, 2:20 PM
leonardchan committed rL367157: [NewPM] Run avx*-builtins.c tests under the new pass manager only.
[NewPM] Run avx*-builtins.c tests under the new pass manager only
Jul 26 2019, 2:19 PM
leonardchan closed D65110: [NewPM] Run avx*-builtins.c tests under the new pass manager only.
Jul 26 2019, 2:19 PM · Restricted Project, Restricted Project
leonardchan added a comment to D65110: [NewPM] Run avx*-builtins.c tests under the new pass manager only.

*ping*

Jul 26 2019, 10:48 AM · Restricted Project, Restricted Project

Jul 25 2019

leonardchan committed rG007f674c6a4e: Reland the "[NewPM] Port Sancov" patch from rL365838. No functional changes… (authored by leonardchan).
Reland the "[NewPM] Port Sancov" patch from rL365838. No functional changes…
Jul 25 2019, 1:55 PM
leonardchan committed rL367053: Reland the "[NewPM] Port Sancov" patch from rL365838. No functional.
Reland the "[NewPM] Port Sancov" patch from rL365838. No functional
Jul 25 2019, 1:54 PM

Jul 24 2019

leonardchan updated the diff for D65110: [NewPM] Run avx*-builtins.c tests under the new pass manager only.
Jul 24 2019, 11:29 AM · Restricted Project, Restricted Project

Jul 22 2019

leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

I created D65110 if we're ok with just using the new PM.

Jul 22 2019, 1:27 PM
leonardchan created D65110: [NewPM] Run avx*-builtins.c tests under the new pass manager only.
Jul 22 2019, 1:26 PM · Restricted Project, Restricted Project

Jul 17 2019

leonardchan updated subscribers of D64843: hwasan: Initialize the pass only once..

cc: @fedor.sergeev @philip.pfaffe on this

Jul 17 2019, 3:25 PM · Restricted Project, Restricted Project

Jul 15 2019

leonardchan committed rGbb147aabc68c: Revert "[NewPM] Port Sancov" (authored by leonardchan).
Revert "[NewPM] Port Sancov"
Jul 15 2019, 4:20 PM
leonardchan added a reverting change for rG5652f35817f0: [NewPM] Port Sancov: rGbb147aabc68c: Revert "[NewPM] Port Sancov".
Jul 15 2019, 4:19 PM
leonardchan committed rL366153: Revert "[NewPM] Port Sancov".
Revert "[NewPM] Port Sancov"
Jul 15 2019, 4:19 PM

Jul 12 2019

leonardchan committed rG223573c8ba44: Remove unused methods in Sancov. (authored by leonardchan).
Remove unused methods in Sancov.
Jul 12 2019, 11:11 AM
leonardchan committed rL365931: Remove unused methods in Sancov..
Remove unused methods in Sancov.
Jul 12 2019, 11:10 AM
leonardchan added inline comments to D62888: [NewPM] Port Sancov.
Jul 12 2019, 11:10 AM · Restricted Project, Restricted Project

Jul 11 2019

leonardchan committed rG5652f35817f0: [NewPM] Port Sancov (authored by leonardchan).
[NewPM] Port Sancov
Jul 11 2019, 3:36 PM
leonardchan committed rL365838: [NewPM] Port Sancov.
[NewPM] Port Sancov
Jul 11 2019, 3:36 PM
leonardchan closed D62888: [NewPM] Port Sancov.
Jul 11 2019, 3:36 PM · Restricted Project, Restricted Project
leonardchan added a comment to D62888: [NewPM] Port Sancov.

*ping*

Jul 11 2019, 1:42 PM · Restricted Project, Restricted Project

Jul 10 2019

leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

*ping* Is it ok to proceed with only checking the new PM output for these tests? If so I could just edit my previous patch to remove the legacy PM run lines since they already include the bitcasts from the new PM.

Jul 10 2019, 2:55 PM

Jul 8 2019

leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

What if we just only check the output from the new pass manager. I don't think I care about the differences between the two.

Jul 8 2019, 8:17 PM
leonardchan accepted D64331: [LegalizeTypes] Fix saturation bug for smul.fix.sat.

LGTM. Good catch

Jul 8 2019, 8:10 PM · Restricted Project
leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

There's some inliner running because the intrinsics are implemented as always_inline functions and they are clearly being inlined in -O0. In a previous post, Chandler said the new PM has a special inliner for always_inline in -O0 and the old pass manager just used the normal inliner.

Jul 8 2019, 4:33 PM
leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

I skimmed D63174 but haven't applied either of these patches to test locally, so I may not have the full picture.

IMO, we do not want clang regression tests running -instcombine/-instsimplify. That can cause clang tests to break when an underlying LLVM change is made. Forcing LLVM devs to depend on clang and fix the resulting breakage is backwards and unexpected extra work. This has happened to me several times.

As a compromise to the -O0 IR explosion, we do have precedent for running the optimizer's -mem2reg pass since that doesn't change frequently at this point.

And I haven't tried this, but we do have utils/update_cc_test_checks.py - this is supposed to take the manual labor out of generating assertions in the same way that we do in the optimizer and codegen regression tests with utils/update_test_checks.py and utils/update_llc_test_checks.py. Can you start with that and remove the irrelevant CHECK lines, so only the common/important lines remain? Or just use independent FileCheck '--check-prefixes'?

I definitely agree running -instcombine would be bad since it can replace squences with other sequences. -instsimplify is a little less scary because our intrinsic tests shouldn't really have a lot of things that are trivially reducible. Though that may not be as true as I want it to be. The main issue we seemed to need -instsimplify for with the new pass manager is to merge redundant bitcasts. The inliner in the old pass manager seemed to do that itself, but the new pass manager's always inliner doesn't.

Jul 8 2019, 1:54 PM
leonardchan added a comment to D62888: [NewPM] Port Sancov.

*ping* @chandlerc

Jul 8 2019, 12:51 PM · Restricted Project, Restricted Project

Jul 2 2019

leonardchan updated the diff for D62888: [NewPM] Port Sancov.
Jul 2 2019, 7:05 PM · Restricted Project, Restricted Project
leonardchan added inline comments to D62888: [NewPM] Port Sancov.
Jul 2 2019, 7:05 PM · Restricted Project, Restricted Project

Jul 1 2019

leonardchan added a comment to D62888: [NewPM] Port Sancov.

ping @chandlerc

Jul 1 2019, 7:42 PM · Restricted Project, Restricted Project

Jun 28 2019

leonardchan committed rGda47e2cac381: Revert "[clang][NewPM] Fix broken profile test" (authored by leonardchan).
Revert "[clang][NewPM] Fix broken profile test"
Jun 28 2019, 5:11 PM
leonardchan added a reverting change for rGab2c0ed01edf: [clang][NewPM] Fix broken profile test: rGda47e2cac381: Revert "[clang][NewPM] Fix broken profile test".
Jun 28 2019, 5:11 PM
leonardchan added a comment to D63155: [clang][NewPM] Fix broken profile test.

Reverted in r364692

Jun 28 2019, 5:11 PM · Restricted Project, Restricted Project
leonardchan committed rL364692: Revert "[clang][NewPM] Fix broken profile test".
Revert "[clang][NewPM] Fix broken profile test"
Jun 28 2019, 5:10 PM
leonardchan added a comment to D63155: [clang][NewPM] Fix broken profile test.

Understood. I'll revert this patch.

Jun 28 2019, 5:09 PM · Restricted Project, Restricted Project
leonardchan added a comment to D63155: [clang][NewPM] Fix broken profile test.

I mean, I'm happy for the patch to be reverted, but I still really don't understand why this fixes the test to work *exactly* the same as w/ the old pass manager and doesn't break any other tests if it is completely wrong? It seems like there must be something strange with the test coverage if this is so far off of correct without any failures...

I also don't understand what fix you are suggesting instead, but maybe you can show a patch?

Jun 28 2019, 4:57 PM · Restricted Project, Restricted Project
leonardchan added a comment to D63155: [clang][NewPM] Fix broken profile test.
In D63155#1563229, @xur wrote:

This patch does not make sense to me.

The reason of failing with -fexperimental-new-pass-manager is because we don't do PGO instrumentation at -O0. This is due to the fact that PGO instrumentation/use passes are under PassBuilder::buildPerModuleDefaultPipeline.

This patch add a pass

MPM.addPass(PGOInstrumentationGenCreateVar(PGOOpt->ProfileFile));

which only gives you the wrong signal of instrumentation is done.

I wrote pass PGOInstrumentationGenCreateVar only for some trick interactions for thinlto under ldd for CSPGO.
Regular FDO should not use it.

The right fix is to enable PGO instrumentation and use in pass builder for O0.

I would like to request to revert this patch.

Jun 28 2019, 4:57 PM · Restricted Project, Restricted Project
leonardchan accepted D52847: [clang-doc] Handle anonymous namespaces.
Jun 28 2019, 11:37 AM · Restricted Project, Restricted Project

Jun 27 2019

leonardchan accepted D63897: [libFuzzer] Migrate to the new exception syscalls on Fuchsia.
Jun 27 2019, 2:11 PM · Restricted Project, Restricted Project
leonardchan accepted D63895: [sanitizer_common] Switch from zx_clock_get_new to zx_clock_get.
Jun 27 2019, 1:51 PM · Restricted Project, Restricted Project
leonardchan added a comment to D62088: [compiler-rt][builtins] Scaled Integer log10().

@t.p.northover Would you feel ok reviewing this?

Jun 27 2019, 10:19 AM · Restricted Project, Restricted Project

Jun 26 2019

leonardchan added a comment to D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c.

Any updates on this? I'm thinking that in the meantime maybe we could commit D63174 and work on this while that lands. If so, we could get an upstream new PM buildbot that can catch any new PM regressions.

Jun 26 2019, 1:34 PM

Jun 24 2019

leonardchan added a comment to D62088: [compiler-rt][builtins] Scaled Integer log10().

Hmm is there usually a protocol/etiquette for getting a new built-in submitted to compiler-rt?

Jun 24 2019, 1:18 PM · Restricted Project, Restricted Project
leonardchan added a comment to D62088: [compiler-rt][builtins] Scaled Integer log10().

Is there not a function for that already in compiler-rt? Or is the problem that it doesn't necessarily exist, e.g. if we're supporting a 64-bit scaled integer type but not a 128-bit integer type?

Jun 24 2019, 12:47 PM · Restricted Project, Restricted Project
leonardchan updated the diff for D62088: [compiler-rt][builtins] Scaled Integer log10().
Jun 24 2019, 12:47 PM · Restricted Project, Restricted Project
leonardchan committed rGf336eb344c60: [clang][NewPM] Add RUNS for tests that produce slightly different IR under new… (authored by leonardchan).
[clang][NewPM] Add RUNS for tests that produce slightly different IR under new…
Jun 24 2019, 9:53 AM
leonardchan committed rL364202: [clang][NewPM] Add RUNS for tests that produce slightly different IR under new….
[clang][NewPM] Add RUNS for tests that produce slightly different IR under new…
Jun 24 2019, 9:49 AM