Page MenuHomePhabricator

uabelho (Mikael Holmén)
User

Projects

User does not belong to any projects.

User Details

User Since
Dec 3 2015, 1:10 AM (288 w, 2 d)

Recent Activity

Yesterday

uabelho added inline comments to rGd88f96dff3f1: ARM: support mandatory tail calls for tailcc & swifttailcc.
Fri, Jun 11, 4:11 AM
uabelho added a comment to D102453: [CMake][ELF] Add -fno-semantic-interposition for GCC and Clang>=13.

I noticed that when I compile this patch with gcc 9.3.0 I suddenly see

1122/2282] Building CXX object lib/Object/CMakeFiles/LLVMObject.dir/Archive.cpp.o
In file included from ../lib/Object/Archive.cpp:13:
../include/llvm/Object/Archive.h: In member function 'llvm::object::Archive::child_iterator llvm::object::Archive::child_end() const':
../include/llvm/Object/Archive.h:147:48: warning: '*((void*)&<anonymous> +40)' is used uninitialized in this function [-Wuninitialized]
  147 |     ChildFallibleIterator(const Child &C) : C(C) {}

Do you know if this is anything to worry about?
I just noticed the warning when compiling after a pull.

Fri, Jun 11, 3:58 AM · Restricted Project

Fri, May 28

uabelho added a comment to D102266: [LAA] Also handle pointer phis in ::addAccess..

Thanks!

Fri, May 28, 2:48 AM · Restricted Project

Thu, May 27

uabelho added a comment to D100258: [VPlan] Add first VPlan version of sinkScalarOperands..

Hello!

The following starts failing with htis patch:

opt -loop-vectorize -force-vector-width=2 -S -o - bbi-56568.ll

Result:

Instruction does not dominate all uses!
  %2 = getelementptr inbounds [9 x i16], [9 x i16]* @v_102, i16 0, i16 undef
  %7 = load i16, i16* %2, align 1
opt: ../lib/Transforms/Vectorize/LoopVectorize.cpp:10200: bool llvm::LoopVectorizePass::processLoop(llvm::Loop *): Assertion `!verifyFunction(*L->getHeader()->getParent(), &dbgs())' failed.

Thanks for the report. The issue appears to be that we sink a uniform replicate recipe. We only generate lane 0 for such recipes, so sinking should not be beneficial and it causes the crash because all users use lane 0, which will be generated in a conditional block after sinking. Should be fixed in 38641ddf3e56

Thu, May 27, 10:03 PM · Restricted Project
uabelho added a comment to D100258: [VPlan] Add first VPlan version of sinkScalarOperands..

The following starts failing with htis patch:

opt -loop-vectorize -force-vector-width=2 -S -o - bbi-56568.ll

Result:

Instruction does not dominate all uses!
  %2 = getelementptr inbounds [9 x i16], [9 x i16]* @v_102, i16 0, i16 undef
  %7 = load i16, i16* %2, align 1
opt: ../lib/Transforms/Vectorize/LoopVectorize.cpp:10200: bool llvm::LoopVectorizePass::processLoop(llvm::Loop *): Assertion `!verifyFunction(*L->getHeader()->getParent(), &dbgs())' failed.

Thu, May 27, 3:26 AM · Restricted Project

Wed, May 26

uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

Silly me. I've accounted for inner loops but not irreducible CFG cycles, which have exactly same problems but not detectable. I need to exclude loops with irreducible CFG.

Wed, May 26, 4:29 AM · Restricted Project
uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

@uabelho you are right. The problem is loop RPOT processes blocks in order (bb2, bb12, bb4), which is not correct. The expected order is (bb2, bb4, bb12). No clue why this happened, investigating.

Wed, May 26, 3:54 AM · Restricted Project
uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

@uabelho Looking into your example, I don't think enough evidence it's a miscompile. Your test has non-side-effecting infinite loop, which has undefined behavior. So it's legal to make the replacement. Can you construct the example without an infinite loop?

Wed, May 26, 2:09 AM · Restricted Project
uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

Thanks, I'll see into the test and revert it if it's indeed a bug.

Wed, May 26, 1:57 AM · Restricted Project
uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

Just a heads up, I think I'm seeing a miscompile with this patch.
I'll dig further and try to extract a reproducer.

Wed, May 26, 1:27 AM · Restricted Project

Tue, May 25

uabelho added a comment to D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3).

Just a heads up, I think I'm seeing a miscompile with this patch.
I'll dig further and try to extract a reproducer.

Tue, May 25, 11:13 PM · Restricted Project

Mon, May 24

uabelho added a comment to D102116: [LoopIdiom] 'logical right-shift until zero' ('count active bits') "on steroids" idiom recognition..
Mon, May 24, 3:39 AM · Restricted Project
uabelho added a comment to D102966: [CVP] Guard against poison in common phi value transform (PR50399).

I've verified that this indeed solves the problem I saw in
https://bugs.llvm.org/show_bug.cgi?id=50399 .
Thanks!

Mon, May 24, 3:07 AM · Restricted Project

Sun, May 23

uabelho added a comment to D102116: [LoopIdiom] 'logical right-shift until zero' ('count active bits') "on steroids" idiom recognition..

THere seems to be something problematic with this patch.
With

opt -enable-new-pm=0 -o /dev/null bbi-56362_2.ll -loop-idiom

I get

Sun, May 23, 11:26 PM · Restricted Project

Wed, May 19

uabelho added a comment to rGa917fb89dc28: [LVI] Simplify and generalize handling of clamp patterns.

I see a miscompile with this patch, I wrote
https://bugs.llvm.org/show_bug.cgi?id=50399
about it.

Wed, May 19, 12:01 AM

Tue, May 18

uabelho edited reviewers for D102707: Fix non-global-value-max-name-size not considered by LLParser, added: hfinkel, chandlerc; removed: uabelho.

Adding the reviewers of
https://reviews.llvm.org/D41296
which introduced the name capping here too.

Tue, May 18, 9:02 PM · Restricted Project
uabelho added a comment to D41296: Limit size of non-GlobalValue name.

Why don't we just cap all names at some point (and then just start adding numbers as we generally do to break degeneracies). It seems like, otherwise, we'll end up with these kinds of fixes in many places. Fixing this in one common place seems better.

This change has the unfortunate side effect of creating unexpected error messages in the LLParser that have been observed in software using LLVM. Reading the discussion here does not indicate that this effect was intended.

It can even lead to cases where we can't read our own output. To see how this happens, let's simulate a much smaller limit of 4. The normal output of the test case would have been (I've stripped the metadata here):

I think the above problem is similar to what is described in
https://bugs.llvm.org/show_bug.cgi?id=45899

Tue, May 18, 9:00 PM · Restricted Project

May 12 2021

uabelho added a comment to D102266: [LAA] Also handle pointer phis in ::addAccess..

Thanks! I've verified that this fixes the crashes I saw.

May 12 2021, 12:29 AM · Restricted Project

May 11 2021

uabelho added a comment to D99294: [VPlan] Representing backedge def-use feeding reduction phis..

I wrote a PR about a LV-crash that started happening with this patch:
https://bugs.llvm.org/show_bug.cgi?id=50298

May 11 2021, 3:47 AM · Restricted Project

May 10 2021

uabelho added a comment to D101286: [LAA] Support pointer phis in loop by analyzing each incoming pointer..

I noticed that loop-distribute started crashing with this patch, see
https://bugs.llvm.org/show_bug.cgi?id=50288

May 10 2021, 8:17 AM · Restricted Project

May 4 2021

uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..

E.g.

opt -slp-vectorizer -S -o - slp2.ll -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900

now results in

define void @foo(%rec* %in_p) #0 {
entry:
  %ptr1 = getelementptr inbounds %rec, %rec* %in_p, i16 0, i32 2
  %ptr2 = getelementptr inbounds %rec, %rec* %in_p, i16 0, i32 0
  %0 = insertelement <2 x i16*> poison, i16* %ptr2, i32 0
  %1 = insertelement <2 x i16*> %0, i16* %ptr1, i32 1
  %2 = call <2 x i16> @llvm.masked.gather.v2i16.v2p0i16(<2 x i16*> %1, i32 1, <2 x i1> <i1 true, i1 true>, <2 x i16> undef)
  store <2 x i16> %2, <2 x i16>* bitcast (%rec* @g to <2 x i16>*), align 1
  ret void
}

But before this patch it didn't use llvm.masked.gather.
And as far as I can see masked gather is not legal for this target.

Well, this should not happen because of the tiny vectorization tree. I'll revert the patch and will add some extra detection/rework it for better cost estimation.

May 4 2021, 4:54 AM · Restricted Project
uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..

I'm seeing a strange case with this patch where I now get calls to

llvm.masked.gather.v2i16.v2p0i16

after SLP vectorizer and before we didn't?
Masked gather is not legal on my target. Something seems to be backwards?

In my case the cost as computed by TTI->getGatherScatterOpCost (so the cost prior to this patch) is 6 but calculated in the new way (since masked gather is not legal) I get the cost 0. getGatherCost(VL) returns 2 and then getEntryCost(It->get()) 2 as well so VecLdCost now ends up as 0.

If the masked gather is not legal, it should be converted to a regular gather by scalarizeMaskedGather function (called by ScalarizeMaskedMemIntrinLegacyPass::runOnFunction), that's why we calculate it as a regular gather

So you say it is expected that with this patch, for a target where masked gather is not legal, the SLP Vectorizer should now suddenly introduce @llvm.masked.gather where it didn't before?

Well, generally speaking, yes. Just if it is not legal, it should be scalarized and turned into a regular gather later. And the patch calculates the cost of the gather, if it is not legal

May 4 2021, 4:32 AM · Restricted Project
uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..
opt -slp-vectorizer -S -o - slp2.ll -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900

now results in

define void @foo(%rec* %in_p) #0 {
entry:
  %ptr1 = getelementptr inbounds %rec, %rec* %in_p, i16 0, i32 2
  %ptr2 = getelementptr inbounds %rec, %rec* %in_p, i16 0, i32 0
  %0 = insertelement <2 x i16*> poison, i16* %ptr2, i32 0
  %1 = insertelement <2 x i16*> %0, i16* %ptr1, i32 1
  %2 = call <2 x i16> @llvm.masked.gather.v2i16.v2p0i16(<2 x i16*> %1, i32 1, <2 x i1> <i1 true, i1 true>, <2 x i16> undef)
  store <2 x i16> %2, <2 x i16>* bitcast (%rec* @g to <2 x i16>*), align 1
  ret void
}

But before this patch it didn't use llvm.masked.gather.
And as far as I can see masked gather is not legal for this target.

May 4 2021, 4:28 AM · Restricted Project
uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..

I'm seeing a strange case with this patch where I now get calls to

llvm.masked.gather.v2i16.v2p0i16

after SLP vectorizer and before we didn't?
Masked gather is not legal on my target. Something seems to be backwards?

In my case the cost as computed by TTI->getGatherScatterOpCost (so the cost prior to this patch) is 6 but calculated in the new way (since masked gather is not legal) I get the cost 0. getGatherCost(VL) returns 2 and then getEntryCost(It->get()) 2 as well so VecLdCost now ends up as 0.

If the masked gather is not legal, it should be converted to a regular gather by scalarizeMaskedGather function (called by ScalarizeMaskedMemIntrinLegacyPass::runOnFunction), that's why we calculate it as a regular gather

May 4 2021, 4:25 AM · Restricted Project
uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..

I'm seeing a strange case with this patch where I now get calls to

llvm.masked.gather.v2i16.v2p0i16

after SLP vectorizer and before we didn't?
Masked gather is not legal on my target. Something seems to be backwards?

May 4 2021, 2:12 AM · Restricted Project
uabelho added a comment to D101297: [SLP]Allow masked gathers only if allowed by target..

I'm seeing a strange case with this patch where I now get calls to

llvm.masked.gather.v2i16.v2p0i16

after SLP vectorizer and before we didn't?
Masked gather is not legal on my target. Something seems to be backwards?

May 4 2021, 1:26 AM · Restricted Project

Apr 27 2021

uabelho added a comment to D100581: [Clang] -Wunused-but-set-parameter and -Wunused-but-set-variable.

I noticed that with this patch
libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp
fails:

error: 'warning' diagnostics seen but not expected: 
  File /repo/uabelho/master-github/libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp Line 51: variable 's' set but not used
1 error generated.

(I don't know anything about the testcase I just noticed it failed when trying to uplift my downstream repo.)

Apr 27 2021, 12:46 AM · Restricted Project, Restricted Project, Restricted Project

Apr 26 2021

uabelho added a comment to D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.

Use
#ifdef clang
#if has_warning("-Wdeprecated-copy")
instead of
#if defined(
clang) && has_warning("-Wdeprecated-copy")
as the latter seems to break gcc bots.

I have no idea if this is the best fix but it works for me with clang 8 and gcc 9.3.0.

Best fix is remove all deprecated things but yeah, for now this is ok.

Apr 26 2021, 11:35 PM · Restricted Project
uabelho committed rG33f04e485c7d: Only ignore -Wdeprecated-copy if the used compiler supports the warning (authored by uabelho).
Only ignore -Wdeprecated-copy if the used compiler supports the warning
Apr 26 2021, 11:33 PM
uabelho closed D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.
Apr 26 2021, 11:32 PM · Restricted Project
uabelho added a reviewer for D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning: xbolva00.

If you don't want to review this fix of your patch https://reviews.llvm.org/rG9658d045926545e62cc3f963fe611d7c5d0c9d98 then please add someone who can.

Apr 26 2021, 8:47 AM · Restricted Project
uabelho added a comment to D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.

Use
#ifdef clang
#if has_warning("-Wdeprecated-copy")
instead of
#if defined(
clang) && has_warning("-Wdeprecated-copy")
as the latter seems to break gcc bots.

Apr 26 2021, 8:44 AM · Restricted Project
uabelho updated the diff for D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.

Use
#ifdef clang
#if has_warning("-Wdeprecated-copy")
instead of
#if defined(
clang) && has_warning("-Wdeprecated-copy")
as the latter seems to break gcc bots.

Apr 26 2021, 8:41 AM · Restricted Project
uabelho added a comment to D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.

Thanks

Apr 26 2021, 5:47 AM · Restricted Project
uabelho added a comment to rG9658d0459265: [utils] Disable -Wdeprecated-copy for googlemock/gtest.

Changing the added

#ifdef __clang__

to

#if defined(__clang__) && __has_warning("-Wdeprecated-copy")

seems to work on clang 8 at least.

Yes please commit, best fix.

What I meant that change ifdef check to if clang > 8 then use pragma to disable warning :)

Can you please commit it if you're confident it's the proper fix of your patch?

There have been several fixes around these deprecated-copy warnings already and I don't want to get tangled into this as well.

Can you please prepare patch and verify build with clang 8 is warning free now? I dont use clang 8 nor any public bots. I will check your patch.

Apr 26 2021, 5:43 AM
uabelho requested review of D101288: Only ignore -Wdeprecated-copy if the used compiler supports the warning.
Apr 26 2021, 5:37 AM · Restricted Project
uabelho added a comment to rG9658d0459265: [utils] Disable -Wdeprecated-copy for googlemock/gtest.

Changing the added

#ifdef __clang__

to

#if defined(__clang__) && __has_warning("-Wdeprecated-copy")

seems to work on clang 8 at least.

Yes please commit, best fix.

What I meant that change ifdef check to if clang > 8 then use pragma to disable warning :)

Apr 26 2021, 5:04 AM
uabelho added a comment to rG9658d0459265: [utils] Disable -Wdeprecated-copy for googlemock/gtest.

Changing the added

#ifdef __clang__

to

#if defined(__clang__) && __has_warning("-Wdeprecated-copy")

seems to work on clang 8 at least.

Apr 26 2021, 3:38 AM
uabelho added a comment to rG9658d0459265: [utils] Disable -Wdeprecated-copy for googlemock/gtest.

Hi,

This doesn't work when building with e.g. clang8:

/proj/flexasic/app/llvm/8.0/bin/clang++  -march=corei7  -DGTEST_HAS_RTTI=0 -DGTEST_HAS_TR1_TUPLE=0 -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Ilib/Testing/Support -I../lib/Testing/Support -Iinclude -I../include -I../utils/unittest/googletest/include -I../utils/unittest/googlemock/include -fPIC -fvisibility-inlines-hidden -Werror -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -DNDEBUG    -fno-exceptions -fno-rtti -UNDEBUG -std=c++14 -MD -MT lib/Testing/Support/CMakeFiles/LLVMTestingSupport.dir/SupportHelpers.cpp.o -MF lib/Testing/Support/CMakeFiles/LLVMTestingSupport.dir/SupportHelpers.cpp.o.d -o lib/Testing/Support/CMakeFiles/LLVMTestingSupport.dir/SupportHelpers.cpp.o -c ../lib/Testing/Support/SupportHelpers.cpp
In file included from ../lib/Testing/Support/SupportHelpers.cpp:2:
In file included from ../include/llvm/Testing/Support/SupportHelpers.h:18:
In file included from ../utils/unittest/googlemock/include/gmock/gmock-matchers.h:53:
In file included from ../utils/unittest/googlemock/include/gmock/internal/gmock-internal-utils.h:49:
In file included from ../utils/unittest/googletest/include/gtest/gtest.h:62:
In file included from ../utils/unittest/googletest/include/gtest/gtest-param-test.h:193:
../utils/unittest/googletest/include/gtest/internal/gtest-param-util-generated.h:59:34: error: unknown warning group '-Wdeprecated-copy', ignored [-Werror,-Wunknown-warning-option]
#pragma clang diagnostic ignored "-Wdeprecated-copy"
                                 ^
In file included from ../lib/Testing/Support/SupportHelpers.cpp:2:
In file included from ../include/llvm/Testing/Support/SupportHelpers.h:18:
../utils/unittest/googlemock/include/gmock/gmock-matchers.h:63:34: error: unknown warning group '-Wdeprecated-copy', ignored [-Werror,-Wunknown-warning-option]
#pragma clang diagnostic ignored "-Wdeprecated-copy"
                                 ^
2 errors generated.

So please change it to clang > 8.

Apr 26 2021, 2:27 AM

Apr 25 2021

uabelho added a comment to D79714: [Diagnostics] Restore -Wdeprecated warning when user-declared copy assignment operator is defined as deleted (PR45634).

I pushed a fix to just disable this warning for googlemock/gtest.

Apr 25 2021, 10:53 PM · Restricted Project
uabelho added a comment to rG9658d0459265: [utils] Disable -Wdeprecated-copy for googlemock/gtest.

This doesn't work when building with e.g. clang8:

Apr 25 2021, 10:42 PM

Apr 23 2021

uabelho added a comment to D79714: [Diagnostics] Restore -Wdeprecated warning when user-declared copy assignment operator is defined as deleted (PR45634).

Can you try this fix?

diff --git a/libcxx/utils/libcxx/test/params.py b/libcxx/utils/libcxx/test/params.py
index ddf277dea246..abf712e78a61 100644
--- a/libcxx/utils/libcxx/test/params.py
+++ b/libcxx/utils/libcxx/test/params.py
@@ -12,6 +12,7 @@ from libcxx.test.features import _isMSVC
 _warningFlags = [
   '-Werror',
   '-Wall',
+  '-Wno-deprecated-copy',
   '-Wextra',
   '-Wshadow',
   '-Wundef',
Apr 23 2021, 8:26 AM · Restricted Project
uabelho added a comment to D79714: [Diagnostics] Restore -Wdeprecated warning when user-declared copy assignment operator is defined as deleted (PR45634).

With this commit I get failures in the following testcases when building check-runtimes on trunk:

Failed Tests (29):
  libc++ :: libcxx/debug/containers/db_sequence_container_iterators.pass.cpp
  libc++ :: libcxx/gdb/gdb_pretty_printer_test.sh.cpp
  libc++ :: std/containers/sequences/vector.bool/assign_copy.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/assign_move.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/copy.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/copy_alloc.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/emplace.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/erase_iter.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/erase_iter_iter.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/insert_iter_initializer_list.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/insert_iter_iter_iter.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/insert_iter_size_value.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/insert_iter_value.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/iterators.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/move.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/move_alloc.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/resize_size.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/resize_size_value.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/shrink_to_fit.pass.cpp
  libc++ :: std/containers/sequences/vector.bool/size.pass.cpp
  libc++ :: std/containers/sequences/vector/vector.cons/deduct.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.members/left_shift.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.members/op_eq_eq.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.members/right_shift.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.members/to_ullong.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.members/to_ulong.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.operators/op_and.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.operators/op_not.pass.cpp
  libc++ :: std/utilities/template.bitset/bitset.operators/op_or.pass.cpp

They all get -Wdeprecated-copy warnigns and then with -Werror they fail.
Is this something you've seen or considered?

Apr 23 2021, 4:43 AM · Restricted Project

Apr 22 2021

uabelho added a comment to D100073: [libcxx][iterator] adds `std::indirectly_readable` and `std::indirectly_writable`.

With this patch I get errors in all the new testcases. I get

Apr 22 2021, 1:24 AM · Restricted Project

Apr 16 2021

uabelho added a comment to D100640: [SimplifyCFG] Skip dbg intrinsics when checking for branch-only BBs..

I've verified that this fixes the problem I saw. Thanks!

Apr 16 2021, 4:40 AM · Restricted Project

Apr 15 2021

uabelho added a comment to D100329: [SimplifyCFG] Allow hoisting terminators only with HoistCommonInsts=false..

Hi,

This patch seems to make -simplifycfg generate different code with/without dbg intrinsics present.
So
opt -simplifycfg -S -o - scfg.ll
and
opt -strip-debug -o - -S scfg.ll | opt -simplifycfg -S -o -
give different results for the attached scfg.ll.

Apr 15 2021, 10:15 PM · Restricted Project

Apr 14 2021

uabelho added a comment to D100264: [SCEV] Don't walk uses of phis without SCEV expression when forgetting.

I wrote
https://bugs.llvm.org/show_bug.cgi?id=49967
about a crash that started appearing with this patch.

Apr 14 2021, 11:45 PM · Restricted Project
uabelho added a comment to D100329: [SimplifyCFG] Allow hoisting terminators only with HoistCommonInsts=false..

This patch seems to make -simplifycfg generate different code with/without dbg intrinsics present.
So
opt -simplifycfg -S -o - scfg.ll
and
opt -strip-debug -o - -S scfg.ll | opt -simplifycfg -S -o -
give different results for the attached scfg.ll.

Apr 14 2021, 5:48 AM · Restricted Project
uabelho added a comment to D100163: [MSSA] Rename uses in IDF regardless of new def position in basic block..

Test added in 1e0b813fc082.

Apr 14 2021, 12:24 AM · Restricted Project

Apr 12 2021

uabelho added a comment to D100163: [MSSA] Rename uses in IDF regardless of new def position in basic block..

Great, thanks for the fix!

Apr 12 2021, 5:57 AM · Restricted Project

Apr 11 2021

uabelho committed rG2dd22da965ff: [libtooling][clang-tidy] Fix compiler warnings in testcase [NFC] (authored by uabelho).
[libtooling][clang-tidy] Fix compiler warnings in testcase [NFC]
Apr 11 2021, 11:33 PM

Apr 9 2021

uabelho added a comment to D99843: [LoopRotate] Don't split loop pass manager.

Do you know how this change affects the resulting code on average?

Apr 9 2021, 2:06 AM · Restricted Project

Apr 8 2021

uabelho committed rG2a1f87167cc0: [NVPTX] Fix compiler warning in NDEBUG build [NFC] (authored by uabelho).
[NVPTX] Fix compiler warning in NDEBUG build [NFC]
Apr 8 2021, 4:22 AM

Apr 7 2021

uabelho added a comment to D87163: [DSE] Switch to MemorySSA-backed DSE by default..

I wrote
https://bugs.llvm.org/show_bug.cgi?id=49859
about a miscompile that started occuring when turning on memoryssa again in DSE.
I suspect that licm doesn't keep memoryssa updated properly.

Apr 7 2021, 1:50 AM · Restricted Project, Restricted Project

Apr 6 2021

uabelho added inline comments to D98222: [SCEV] Use trip count information to improve shift recurrence ranges.
Apr 6 2021, 5:27 AM · Restricted Project

Apr 1 2021

uabelho added a comment to D94378: [LoopDeletion] Handle inner loops w/untaken backedges.

I wrote
https://bugs.llvm.org/show_bug.cgi?id=49802
about a problem that started happening with this commit.

Apr 1 2021, 1:52 AM · Restricted Project

Mar 31 2021

uabelho added a comment to D96385: [libc++] [P1032] Finish constexpr-ifying <iterator>, <string_view>, <tuple>, <utility>..

What do you think about doing something about the failing test?

Mar 31 2021, 6:07 AM · Restricted Project

Mar 30 2021

uabelho added inline comments to D98222: [SCEV] Use trip count information to improve shift recurrence ranges.
Mar 30 2021, 12:41 AM · Restricted Project

Mar 26 2021

uabelho added inline comments to D98967: [Analysis]Add getPointersDiff function to improve compile time..
Mar 26 2021, 7:06 AM · Restricted Project
uabelho added inline comments to D98967: [Analysis]Add getPointersDiff function to improve compile time..
Mar 26 2021, 5:53 AM · Restricted Project
uabelho added a comment to D96385: [libc++] [P1032] Finish constexpr-ifying <iterator>, <string_view>, <tuple>, <utility>..

I noticed that the following test failed with this patch:

Failed Tests (1):
  libc++ :: std/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp

It hits an assertion:

clang-13: /repo/uabelho/master-github/clang/lib/AST/ExprConstant.cpp:5947: bool HandleUnionActiveMemberChange((anonymous namespace)::EvalInfo &, const clang::Expr *, const (anonymous namespace)::LValue &): Assertion `declaresSameEntity(Elt->getType()->getAsCXXRecordDecl(), LHS.Designator.Entries[PathLength] .getAsBaseOrMember().getPointer())' failed.
PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace, preprocessed source, and associated run script.
Stack dump:
0.	Program arguments: /repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13 -cc1 -triple x86_64-unknown-linux-gnu -emit-obj -mrelax-all --mrelax-relocations -disable-free -main-file-name convert_copy.pass.cpp -mrelocation-model static -mframe-pointer=all -fmath-errno -fno-rounding-math -mconstructor-aliases -munwind-tables -target-cpu x86-64 -tune-cpu generic -debugger-tuning=gdb -v -fcoverage-compilation-dir=/repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign -nostdinc++ -resource-dir /repo/uabelho/master-github/llvm/build-all-builtins/lib/clang/13.0.0 -include /repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/libcxx/__config_site -include /repo/uabelho/master-github/libcxx/test/support/nasty_macros.h -I /repo/uabelho/master-github/libcxx/include -I /repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/libcxx/include/c++build -D __STDC_FORMAT_MACROS -D __STDC_LIMIT_MACROS -D __STDC_CONSTANT_MACROS -I /repo/uabelho/master-github/libcxx/test/support -D _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER -D _LIBCPP_DISABLE_AVAILABILITY -D _LIBCPP_HAS_THREAD_API_PTHREAD -D _LIBCPP_ABI_VERSION=1 -internal-isystem /usr/local/include -internal-isystem /usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../x86_64-redhat-linux/include -internal-isystem /repo/uabelho/master-github/llvm/build-all-builtins/lib/clang/13.0.0/include -internal-externc-isystem /include -internal-externc-isystem /usr/include -Werror -Wall -Wextra -Wshadow -Wno-unused-command-line-argument -Wno-attributes -Wno-pessimizing-move -Wno-c++11-extensions -Wno-user-defined-literals -Wno-noexcept-type -Wno-atomic-alignment -Wsign-compare -Wunused-variable -Wunused-parameter -Wunreachable-code -Wno-unused-local-typedef -Werror=thread-safety -Wuser-defined-warnings -Wno-macro-redefined -Wno-macro-redefined -std=c++2b -fdeprecated-macro -fdebug-compilation-dir=/repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign -ferror-limit 19 -fcoroutines-ts -fgnuc-version=4.2.1 -fcxx-exceptions -fexceptions -faddrsig -D__GCC_HAVE_DWARF2_CFI_ASM=1 -o /tmp/convert_copy-5d8b65.o -x c++ /repo/uabelho/master-github/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp
1.	/repo/uabelho/master-github/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp:111:5: current parser token '{'
2.	/repo/uabelho/master-github/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp:105:1: parsing function body 'main'
3.	/repo/uabelho/master-github/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp:105:1: in compound statement ('{}')
 #0 0x0000000002ada0f3 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x2ada0f3)
 #1 0x0000000002ad7dae llvm::sys::RunSignalHandlers() (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x2ad7dae)
 #2 0x0000000002ada5b6 SignalHandler(int) Signals.cpp:0:0
 #3 0x00007f8fa58f7630 __restore_rt sigaction.c:0:0
 #4 0x00007f8fa302a387 raise (/lib64/libc.so.6+0x36387)
 #5 0x00007f8fa302ba78 abort (/lib64/libc.so.6+0x37a78)
 #6 0x00007f8fa30231a6 __assert_fail_base (/lib64/libc.so.6+0x2f1a6)
 #7 0x00007f8fa3023252 (/lib64/libc.so.6+0x2f252)
 #8 0x000000000509b722 HandleUnionActiveMemberChange((anonymous namespace)::EvalInfo&, clang::Expr const*, (anonymous namespace)::LValue const&) ExprConstant.cpp:0:0
 #9 0x0000000005092a9e HandleFunctionCall(clang::SourceLocation, clang::FunctionDecl const*, (anonymous namespace)::LValue const*, llvm::ArrayRef<clang::Expr const*>, (anonymous namespace)::CallRef, clang::Stmt const*, (anonymous namespace)::EvalInfo&, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#10 0x0000000005099c04 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::LValueExprEvaluator>::VisitCallExpr(clang::CallExpr const*) ExprConstant.cpp:0:0
#11 0x000000000508b200 EvaluateLValue(clang::Expr const*, (anonymous namespace)::LValue&, (anonymous namespace)::EvalInfo&, bool) ExprConstant.cpp:0:0
#12 0x0000000005090aca Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#13 0x0000000005117d34 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::VoidExprEvaluator>::VisitBinaryOperator(clang::BinaryOperator const*) ExprConstant.cpp:0:0
#14 0x00000000050918b3 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#15 0x0000000005095631 clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::LValueExprEvaluator, bool>::Visit(clang::Stmt const*) ExprConstant.cpp:0:0
#16 0x000000000508b200 EvaluateLValue(clang::Expr const*, (anonymous namespace)::LValue&, (anonymous namespace)::EvalInfo&, bool) ExprConstant.cpp:0:0
#17 0x0000000005090aca Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#18 0x000000000508c907 EvaluateInPlace(clang::APValue&, (anonymous namespace)::EvalInfo&, (anonymous namespace)::LValue const&, clang::Expr const*, bool) ExprConstant.cpp:0:0
#19 0x000000000509081e EvaluateCallArg(clang::ParmVarDecl const*, clang::Expr const*, (anonymous namespace)::CallRef, (anonymous namespace)::EvalInfo&, bool) ExprConstant.cpp:0:0
#20 0x00000000050afe7f EvaluateArgs(llvm::ArrayRef<clang::Expr const*>, (anonymous namespace)::CallRef, (anonymous namespace)::EvalInfo&, clang::FunctionDecl const*, bool) ExprConstant.cpp:0:0
#21 0x0000000005118ca5 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::VoidExprEvaluator>::handleCallExpr(clang::CallExpr const*, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#22 0x0000000005115769 clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::VoidExprEvaluator, bool>::Visit(clang::Stmt const*) ExprConstant.cpp:0:0
#23 0x000000000511619b clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::VoidExprEvaluator, bool>::Visit(clang::Stmt const*) ExprConstant.cpp:0:0
#24 0x00000000050918b3 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#25 0x00000000050b4fd7 EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#26 0x00000000050b550a EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#27 0x000000000509289e HandleFunctionCall(clang::SourceLocation, clang::FunctionDecl const*, (anonymous namespace)::LValue const*, llvm::ArrayRef<clang::Expr const*>, (anonymous namespace)::CallRef, clang::Stmt const*, (anonymous namespace)::EvalInfo&, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#28 0x00000000051192d7 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::VoidExprEvaluator>::handleCallExpr(clang::CallExpr const*, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#29 0x0000000005115769 clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::VoidExprEvaluator, bool>::Visit(clang::Stmt const*) ExprConstant.cpp:0:0
#30 0x00000000050918b3 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#31 0x00000000050b4fd7 EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#32 0x00000000050b550a EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#33 0x000000000509289e HandleFunctionCall(clang::SourceLocation, clang::FunctionDecl const*, (anonymous namespace)::LValue const*, llvm::ArrayRef<clang::Expr const*>, (anonymous namespace)::CallRef, clang::Stmt const*, (anonymous namespace)::EvalInfo&, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#34 0x0000000005099c04 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::LValueExprEvaluator>::VisitCallExpr(clang::CallExpr const*) ExprConstant.cpp:0:0
#35 0x000000000508b200 EvaluateLValue(clang::Expr const*, (anonymous namespace)::LValue&, (anonymous namespace)::EvalInfo&, bool) ExprConstant.cpp:0:0
#36 0x0000000005090aca Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#37 0x00000000050b4fd7 EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#38 0x00000000050b550a EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#39 0x00000000050b550a EvaluateStmt((anonymous namespace)::StmtResult&, (anonymous namespace)::EvalInfo&, clang::Stmt const*, clang::SwitchCase const*) ExprConstant.cpp:0:0
#40 0x000000000509289e HandleFunctionCall(clang::SourceLocation, clang::FunctionDecl const*, (anonymous namespace)::LValue const*, llvm::ArrayRef<clang::Expr const*>, (anonymous namespace)::CallRef, clang::Stmt const*, (anonymous namespace)::EvalInfo&, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#41 0x00000000050eb527 (anonymous namespace)::ExprEvaluatorBase<(anonymous namespace)::IntExprEvaluator>::handleCallExpr(clang::CallExpr const*, clang::APValue&, (anonymous namespace)::LValue const*) ExprConstant.cpp:0:0
#42 0x00000000050c38b8 clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::IntExprEvaluator, bool>::Visit(clang::Stmt const*) ExprConstant.cpp:0:0
#43 0x0000000005090ca8 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) ExprConstant.cpp:0:0
#44 0x000000000508e130 EvaluateAsRValue((anonymous namespace)::EvalInfo&, clang::Expr const*, clang::APValue&) ExprConstant.cpp:0:0
#45 0x000000000508a2ce clang::Expr::EvaluateAsRValue(clang::Expr::EvalResult&, clang::ASTContext const&, bool) const (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x508a2ce)
#46 0x00000000047ebcb2 clang::Sema::VerifyIntegerConstantExpression(clang::Expr*, llvm::APSInt*, clang::Sema::VerifyICEDiagnoser&, clang::Sema::AllowFoldKind) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x47ebcb2)
#47 0x00000000047e9675 clang::Sema::VerifyIntegerConstantExpression(clang::Expr*, llvm::APSInt*, unsigned int, clang::Sema::AllowFoldKind) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x47e9675)
#48 0x00000000047361a9 clang::Sema::BuildStaticAssertDeclaration(clang::SourceLocation, clang::Expr*, clang::StringLiteral*, clang::SourceLocation, bool) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x47361a9)
#49 0x0000000004475bf8 clang::Parser::ParseStaticAssertDeclaration(clang::SourceLocation&) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x4475bf8)
#50 0x0000000004453815 clang::Parser::ParseDeclaration(clang::DeclaratorContext, clang::SourceLocation&, clang::Parser::ParsedAttributesWithRange&, clang::SourceLocation*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x4453815)
#51 0x00000000044f4fbd clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*, clang::Parser::ParsedAttributesWithRange&) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x44f4fbd)
#52 0x00000000044f3f41 clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x44f3f41)
#53 0x00000000044fde01 clang::Parser::ParseCompoundStatementBody(bool) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x44fde01)
#54 0x00000000044ff055 clang::Parser::ParseFunctionStatementBody(clang::Decl*, clang::Parser::ParseScope&) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x44ff055)
#55 0x0000000004439efd clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&, clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x4439efd)
#56 0x000000000445a096 clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, clang::DeclaratorContext, clang::SourceLocation*, clang::Parser::ForRangeInit*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x445a096)
#57 0x0000000004439095 clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x4439095)
#58 0x0000000004438af5 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x4438af5)
#59 0x00000000044379d6 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x44379d6)
#60 0x000000000443578d clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, bool) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x443578d)
#61 0x000000000442fd48 clang::ParseAST(clang::Sema&, bool, bool) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x442fd48)
#62 0x00000000033796f3 clang::FrontendAction::Execute() (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x33796f3)
#63 0x00000000032f0474 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x32f0474)
#64 0x000000000342aad1 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x342aad1)
#65 0x00000000009de555 cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x9de555)
#66 0x00000000009dc991 ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&) driver.cpp:0:0
#67 0x00000000009dc44c main (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x9dc44c)
#68 0x00007f8fa3016555 __libc_start_main (/lib64/libc.so.6+0x22555)
#69 0x00000000009d93bd _start (/repo/uabelho/master-github/llvm/build-all-builtins/bin/clang-13+0x9d93bd)
clang-13: error: unable to execute command: Aborted
clang-13: error: clang frontend command failed due to signal (use -v to see invocation)
clang version 13.0.0
Target: x86_64-unknown-linux-gnu
Thread model: posix
Mar 26 2021, 1:36 AM · Restricted Project

Mar 24 2021

uabelho added a comment to D98367: [libcxxabi] Use cxx-headers target to consume libcxx headers.

What's your CMake configuration? I'd like to try and reproduce this locally so I can investigate.

Mar 24 2021, 11:23 PM · Restricted Project
uabelho added a comment to D98367: [libcxxabi] Use cxx-headers target to consume libcxx headers.

I don't know what is happening at all, but I noticed that when I do "ninja check-runtimes" with this patch it fails with

[0/1] Running all regression tests
llvm-lit: /repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/libcxxabi/test/lit.site.cfg:60: note: Using configuration variant: libcxxabi
llvm-lit: /repo/uabelho/master-github/libcxx/utils/libcxx/test/config.py:632: note: Setting target_triple to x86_64-unknown-linux-gnu
llvm-lit: /repo/uabelho/master-github/libcxxabi/test/libcxxabi/test/config.py:67: fatal: cxx_headers='/repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/include/c++/v1' is not a directory.

The directory
/repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/include/c++/v1
doesn't exist. The dir
/repo/uabelho/master-github/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins
exists, but there is no "include" in it.
If I search for "v1" in my build dir I find

build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/compiler-rt/lib/fuzzer/libcxx_fuzzer_x86_64/include/c++/v1
build-all-builtins/include/c++/v1

Any idea what's up?

Mar 24 2021, 3:49 AM · Restricted Project

Mar 19 2021

uabelho committed rG6d22ba48ea49: [NVPTX] Fix warning, remove extra ";" [NFC] (authored by uabelho).
[NVPTX] Fix warning, remove extra ";" [NFC]
Mar 19 2021, 1:27 AM
uabelho added inline comments to D96469: [AMDGPU] Use single cache policy operand.
Mar 19 2021, 1:25 AM · Restricted Project

Mar 16 2021

uabelho added a comment to D98278: [test] Add ability to get error messages from CMake for errc substitution.

so perhaps there should be some additional error handling when running the compiled program doesn't work?

Could you try changing line 32 of llvm/cmake/modules/GetErrcMessages.cmake from if (errc_compiled) to if (errc_compiled AND "${errc_exit_code}" STREQUAL "0") and report back if it changes anything? I think that should fix your issue, although it'll fall back to using python's strerror messages. Indeed an oversight of mine.

Mar 16 2021, 4:00 AM · Restricted Project, Restricted Project
uabelho added a comment to D98278: [test] Add ability to get error messages from CMake for errc substitution.

I'm seeing a problem with this. Compiling with gcc 9.3.0 the compilation of the test program works, but then when I run it I get

/repo/uabelho/master-github/llvm/build-all-bbigcc/CMakeFiles/CMakeTmp/cmTC_00188: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by /repo/uabelho/master-github/llvm/build-all-bbigcc/CMakeFiles/CMakeTmp/cmTC_00188)

and this causes everything to fail with

Mar 16 2021, 3:30 AM · Restricted Project, Restricted Project

Mar 10 2021

uabelho added a comment to rG17422038442c: [SimplifyCFG] FoldBranchToCommonDest(): re-lift restrictions on liveout uses of….

I wrote
https://bugs.llvm.org/show_bug.cgi?id=49510
about a problem starting to occur with this change.

Mar 10 2021, 5:30 AM

Mar 3 2021

uabelho added inline comments to D97582: [LegalizeVectorTypes] Improve SplitVecRes_INSERT_SUBVECTOR to handle subvector being in the high half of the split or not at element 0 of the low half..
Mar 3 2021, 10:35 PM · Restricted Project
uabelho committed rG85b67d5fa92d: [lld][MachO] Silence "enumeral and non-enumeral type" warning from gcc (authored by uabelho).
[lld][MachO] Silence "enumeral and non-enumeral type" warning from gcc
Mar 3 2021, 2:03 AM

Mar 2 2021

uabelho added a comment to D86183: [DAGCombine] Remove dead node when it is created by getNegatedExpression.

I wrote https://bugs.llvm.org/show_bug.cgi?id=49393 that seems to start happening with this patch.

Mar 2 2021, 2:14 AM · Restricted Project

Feb 22 2021

uabelho added a comment to D92284: [VPlan] Manage induction value creation using VPValues..

Hi,

We've seen a crash with this patch.
Running

opt -o /dev/null bbi-53235.ll -loop-vectorize

yields

opt: ../lib/Transforms/Vectorize/VPlan.cpp:198: llvm::Value *llvm::VPTransformState::get(llvm::VPValue *, const llvm::VPIteration &): Assertion `hasVectorValue(Def, Instance.Part)' failed.

Thanks for the heads-up. Should be fixed by c7ee57f1dccf

Feb 22 2021, 10:04 PM · Restricted Project
uabelho added a comment to D94376: [MemCpyOpt] Enable MemorySSA by default.
Feb 22 2021, 10:04 PM · Restricted Project, Restricted Project
uabelho added a comment to D92284: [VPlan] Manage induction value creation using VPValues..

We've seen a crash with this patch.
Running

opt -o /dev/null bbi-53235.ll -loop-vectorize

yields

Feb 22 2021, 3:48 AM · Restricted Project
uabelho added a comment to D94376: [MemCpyOpt] Enable MemorySSA by default.

I ran into a crash in memcpyopt with this patch.
Running

Feb 22 2021, 12:25 AM · Restricted Project, Restricted Project

Feb 16 2021

uabelho added inline comments to D88629: [lld-macho] Add ARM64 target arch.
Feb 16 2021, 11:24 PM · Restricted Project, Restricted Project
uabelho committed rGcaff023b7799: [lld] Silence compiler warnings by removing always true/false comparisons (authored by uabelho).
[lld] Silence compiler warnings by removing always true/false comparisons
Feb 16 2021, 11:19 PM
uabelho added inline comments to D96727: [NPM] Properly reset parent loop after loop passes.
Feb 16 2021, 12:32 AM · Restricted Project

Feb 12 2021

uabelho added inline comments to D96160: [dfsan] Add origin chain utils.
Feb 12 2021, 3:41 AM · Restricted Project

Feb 11 2021

uabelho added a comment to D91525: [LoopLoadElim] Make sure all loops are in simplify form. PR48150.

I noticed a new crash with this patch when using the old PM.
I wrote
https://bugs.llvm.org/show_bug.cgi?id=49141
about it.

Feb 11 2021, 1:14 AM · Restricted Project

Feb 10 2021

Herald added a project to D88629: [lld-macho] Add ARM64 target arch: Restricted Project.
Feb 10 2021, 11:28 PM · Restricted Project, Restricted Project

Feb 8 2021

uabelho committed rGeb8c27c60c33: [RISCV] Use std::make_tuple to make some toolchains happy again (authored by uabelho).
[RISCV] Use std::make_tuple to make some toolchains happy again
Feb 8 2021, 5:48 AM

Feb 7 2021

uabelho added inline comments to D95121: [lld-macho][NFC] refactor relocation handling.
Feb 7 2021, 11:25 PM · Restricted Project

Jan 31 2021

uabelho added a comment to D93764: [LoopUnswitch] Implement first version of partial unswitching..

Should be fixed by 10c57268c074. Please let me know if you are seeing any other issues.

Jan 31 2021, 10:18 PM · Restricted Project

Jan 28 2021

uabelho added a comment to D93764: [LoopUnswitch] Implement first version of partial unswitching..

For another program I see

opt: ../lib/Analysis/MemorySSA.cpp:2032: void llvm::MemorySSA::verifyOrderingDominationAndDefUses(llvm::Function &) const: Assertion `dominates(MD, U) && "Memory Def does not dominate it's uses"' failed.

when I run

opt -O1 -inline -loop-unswitch -verify-memoryssa

with this patch but unfortunately I haven't been able to reduce that down to a simpler command line (it doesn't reproduce if I run the passes I get from -debug-pass=Arguments) and the input uses some features we only have downstream so I don't have a reproducer I can share for this :(

Jan 28 2021, 4:41 AM · Restricted Project
uabelho added a comment to D93764: [LoopUnswitch] Implement first version of partial unswitching..

I started seeing crashes with this patch:

Jan 28 2021, 2:57 AM · Restricted Project
uabelho added a comment to rG86991d323133: [LoopUnswitch] Fix logic to avoid unswitching with atomic loads..
Jan 28 2021, 2:57 AM
uabelho added a comment to rG86991d323133: [LoopUnswitch] Fix logic to avoid unswitching with atomic loads..
Jan 28 2021, 2:56 AM

Jan 26 2021

uabelho added a comment to rG6884fbc2c4fb: [JITLink] Enable exception handling for ELF..

Hi Mikael,

Thanks for the heads up. This looks like missing a RTTI symbol. Since this
test doesn't actually execute anything I'll fix it by defining a bogus
definition of _ZTIi in the test itself.

  • Lang.
Jan 26 2021, 1:11 AM

Jan 25 2021

uabelho added a comment to D95217: [LoopVectorize] Fix VPRecipeBuilder::createEdgeMask to correctly generate the mask.

At least the patch seems to fix the problem I saw.
I'll run more tests with it during the night to see nothing unexpected pops up.

Jan 25 2021, 6:12 AM · Restricted Project
uabelho added a comment to rG6884fbc2c4fb: [JITLink] Enable exception handling for ELF..

Hi!

I noticed that the ELF_ehframe_basic.s fail for me when I've compiled llvm-jitlink with gcc.

Btw, we're using gcc 9.3.0.

Jan 25 2021, 5:33 AM
uabelho added a comment to rG6884fbc2c4fb: [JITLink] Enable exception handling for ELF..

I noticed that the ELF_ehframe_basic.s fail for me when I've compiled llvm-jitlink with gcc. The CHECKs in the test pass, but llvm-jitlink ends with

Starting link phase 2 for graph /data/repo/master/llvm/build-all-bbigcc/test/ExecutionEngine/JITLink/X86/Output/ELF_ehframe_basic.s.tmp
JIT session error: Symbols not found: [ _ZTIi ]
/data/repo/master/llvm/build-all-bbigcc/bin/llvm-jitlink: Failed to materialize symbols: { (main, { DW.ref.__gxx_personality_v0, foo, main }) }

It doesn't happen when I compile with clang.
I know nothing about llvm-jitlink, I just saw this when building check-all.

Jan 25 2021, 5:20 AM

Jan 22 2021

uabelho added a comment to D95217: [LoopVectorize] Fix VPRecipeBuilder::createEdgeMask to correctly generate the mask.

That was my epic typo, sorry. It should have been select i1 false, i1 poison, i1 false because the buggy case was encoding the path that visits cond.false.

Great, then I'm slightly less puzzled :) Thanks!

Jan 22 2021, 3:31 AM · Restricted Project
uabelho added a comment to D95217: [LoopVectorize] Fix VPRecipeBuilder::createEdgeMask to correctly generate the mask.

Thanks for fixing this!
I don't know this code at all, but I'm puzzled by this sentence in the summary:

The path for.body -> cond.false -> cond.end should be taken when 'select i1 true, i1 poison, i1 false' holds

Jan 22 2021, 3:06 AM · Restricted Project

Jan 21 2021

uabelho committed rG2b4716d6dff1: [MC] Use std::make_tuple to make some toolchains happy again (authored by uabelho).
[MC] Use std::make_tuple to make some toolchains happy again
Jan 21 2021, 5:13 AM
uabelho added a comment to rG8871a4b4cab8: [Constant] Update ConstantVector::get to return poison if all input elems are….

I wrote a PR about this:
https://bugs.llvm.org/show_bug.cgi?id=48832

Jan 21 2021, 1:13 AM
uabelho added a comment to rG8871a4b4cab8: [Constant] Update ConstantVector::get to return poison if all input elems are….

I've been able to reproduce the problem I see for an in-tree architecture.
So with

opt -mtriple=s390x-unknown-linux -mcpu=z13 -loop-vectorize -S -o - bbi-51947.ll

I get

store <4 x i32> poison, <4 x i32>* %6, align 1

but before this patch I got

store <4 x i32> zeroinitializer, <4 x i32>* %6, align 1

The input is

%arrayt = type [64 x i32]
Jan 21 2021, 1:06 AM

Jan 20 2021

uabelho added a comment to rG8871a4b4cab8: [Constant] Update ConstantVector::get to return poison if all input elems are….

I'm not sure what happens yet, but with this patch I'm seeing a miscompile.
Diffs start occuring after the loop vectorizer. Previously we got this store

store <4 x i32> zeroinitializer, <4 x i32>* %8, align 1, !dbg !16

but now we instead get this:

store <4 x i32> poison, <4 x i32>* %8, align 1, !dbg !16

Are you aware of any problems?

Jan 20 2021, 9:14 AM
uabelho committed rG2aeaaf841b58: [GlobalISel] Add missing operand update when copy is required (authored by ehjogab).
[GlobalISel] Add missing operand update when copy is required
Jan 20 2021, 1:34 AM
uabelho closed D91244: [GlobalISel] Add missing operand update when copy is required.
Jan 20 2021, 1:34 AM · Restricted Project