dim (Dimitry Andric)
User

Projects

User does not belong to any projects.

User Details

User Since
Apr 15 2014, 12:19 PM (201 w, 2 d)

Recent Activity

Sat, Feb 17

dim committed rC325446: [X86] Add 'sahf' CPU feature to frontend.
[X86] Add 'sahf' CPU feature to frontend
Sat, Feb 17, 1:10 PM
dim committed rL325446: [X86] Add 'sahf' CPU feature to frontend.
[X86] Add 'sahf' CPU feature to frontend
Sat, Feb 17, 1:06 PM
dim closed D43394: [X86] Add 'sahf' CPU feature to frontend.
Sat, Feb 17, 1:06 PM
dim retitled D43394: [X86] Add 'sahf' CPU feature to frontend from [X86] Add 'sahf' CPU feature, and emit __LAHFSAHF__ for it to [X86] Add 'sahf' CPU feature to frontend.
Sat, Feb 17, 10:47 AM
dim updated the diff for D43394: [X86] Add 'sahf' CPU feature to frontend.

Remove the __LAHFSAHF__ predefined macro.

Sat, Feb 17, 10:47 AM
dim accepted D43418: [X86] Add 'sahf' to getHostCPUFeatures so -march=native will pick it up correctly..

LGTM.

Sat, Feb 17, 3:53 AM

Fri, Feb 16

dim updated the diff for D43394: [X86] Add 'sahf' CPU feature to frontend.

Added the sahf feature for knm, knl and amdfam10 too.

Fri, Feb 16, 3:24 PM
dim added inline comments to D43394: [X86] Add 'sahf' CPU feature to frontend.
Fri, Feb 16, 2:57 PM
dim created D43394: [X86] Add 'sahf' CPU feature to frontend.
Fri, Feb 16, 9:07 AM

Tue, Feb 13

dim committed rL325028: Make the ctype_byname::widen test cases pass on FreeBSD..
Make the ctype_byname::widen test cases pass on FreeBSD.
Tue, Feb 13, 9:45 AM
dim committed rCXX325028: Make the ctype_byname::widen test cases pass on FreeBSD..
Make the ctype_byname::widen test cases pass on FreeBSD.
Tue, Feb 13, 9:45 AM
dim committed rL325027: Put type attributes after class keyword.
Put type attributes after class keyword
Tue, Feb 13, 9:44 AM
dim committed rCXX325027: Put type attributes after class keyword.
Put type attributes after class keyword
Tue, Feb 13, 9:44 AM
dim closed D43209: Put type attributes after class keyword.
Tue, Feb 13, 9:44 AM
dim committed rT325026: Include <sys/time.h> to get struct timeval definition.
Include <sys/time.h> to get struct timeval definition
Tue, Feb 13, 9:41 AM
dim committed rL325026: Include <sys/time.h> to get struct timeval definition.
Include <sys/time.h> to get struct timeval definition
Tue, Feb 13, 9:41 AM
dim closed D43169: Include <sys/time.h> to get struct timeval definition.
Tue, Feb 13, 9:41 AM

Mon, Feb 12

dim created D43209: Put type attributes after class keyword.
Mon, Feb 12, 2:20 PM
dim added a comment to D43168: Don't use -ldl on BSD.
In D43168#1005380, @dim wrote:

Apparently there is a halide_spawn_thread function in the bitcode. I am unsure if there is any source for that bitcode?

Mon, Feb 12, 10:50 AM
dim added a comment to D43168: Don't use -ldl on BSD.

@asbirlea: Why is -dl and -pthread needed at all? Glancing at the code I don't see any reference to pthreads or dlopen/dlsym...

Mon, Feb 12, 10:40 AM

Sun, Feb 11

dim added a comment to D43159: Modernize: Use nullptr more..

So my main concern with this patch is that nullptr is actually #defined'ed in C++03 mode. That definition comes from the __nullptr header, and therefore we would need to add that header to each include which uses it. Which kind of sucks.

Sun, Feb 11, 2:40 PM
dim committed rCXX324855: Add default C++ ABI libname and include paths for FreeBSD.
Add default C++ ABI libname and include paths for FreeBSD
Sun, Feb 11, 2:34 PM
dim committed rL324855: Add default C++ ABI libname and include paths for FreeBSD.
Add default C++ ABI libname and include paths for FreeBSD
Sun, Feb 11, 2:34 PM
dim closed D43166: Add default C++ ABI libname and include paths for FreeBSD.
Sun, Feb 11, 2:34 PM
dim committed rT324848: Use CMAKE_DL_LIBS and CMAKE_THREAD_LIBS_INIT for Bitcode tests.
Use CMAKE_DL_LIBS and CMAKE_THREAD_LIBS_INIT for Bitcode tests
Sun, Feb 11, 12:28 PM
dim committed rL324848: Use CMAKE_DL_LIBS and CMAKE_THREAD_LIBS_INIT for Bitcode tests.
Use CMAKE_DL_LIBS and CMAKE_THREAD_LIBS_INIT for Bitcode tests
Sun, Feb 11, 12:18 PM
dim closed D43168: Don't use -ldl on BSD.
Sun, Feb 11, 12:18 PM
dim added a comment to D43159: Modernize: Use nullptr more..

LGTM minus a few nits, though it would be nice if you can verify that all the changed headers still compile in -std=c++98 and/or -std=gnu++98 mode.

Sun, Feb 11, 11:55 AM
dim created D43169: Include <sys/time.h> to get struct timeval definition.
Sun, Feb 11, 11:45 AM
dim updated the diff for D43168: Don't use -ldl on BSD.

Update to use a for loop for iterating over CMAKE_DL_LIBS, and while we are here, also use CMake's FindThreads module and CMAKE_THREAD_LIBS_INIT (this will contain -lpthread, if it is necessary for the target system).

Sun, Feb 11, 11:02 AM
dim added a comment to D43168: Don't use -ldl on BSD.

It looks like test-suite has some sort of special handling for test executables, where it uses LDFLAGS instead of target_link_libraries():

Sun, Feb 11, 7:51 AM
dim added a comment to D43168: Don't use -ldl on BSD.

CMAKE_DL_LIBS allows us to fix it once for everybody and forever.

CMAKE_DL_LIBS is already used in llvm, e.g.

if( HAVE_LIBDL )
  set(system_libs ${system_libs} ${CMAKE_DL_LIBS})
endif()

in llvm/lib/Support/CMakeLists.txt

I don't want to repeat this process for AIX, SmartOS (they are now migrating to Clang at least for pkgsrc) etc.

Sun, Feb 11, 7:39 AM
dim added a comment to D43168: Don't use -ldl on BSD.

One other problem is that CMAKE_DL_LIBS is meant for adding to cmake targets, e.g. it only contains the string "dl" on Linux. This means that you would have to add some sort of transformation to change it into "-ldl"... Way too complicated, if you ask me. :)

Sun, Feb 11, 7:12 AM
dim added a comment to D43168: Don't use -ldl on BSD.

Can we use CMAKE_DL_LIBS?

Sun, Feb 11, 7:08 AM
dim created D43168: Don't use -ldl on BSD.
Sun, Feb 11, 7:02 AM

Sat, Feb 10

dim created D43166: Add default C++ ABI libname and include paths for FreeBSD.
Sat, Feb 10, 3:17 PM

Wed, Feb 7

dim added a comment to D43016: Fix for #31362 - ms_abi is implemented incorrectly for larger values (>=16 bytes)..

FWIW, this allows me to build wine again for x86_64, without any crashes or assertions. So that looks good, in any case.

Wed, Feb 7, 2:27 PM

Tue, Feb 6

dim accepted D42972: Look for 32-bit libraries in /usr/lib32 for MIPS O32 on FreeBSD..

LGTM, though a test case would be nice (could be added to tools/clang/test/Driver/freebsd.c)

Tue, Feb 6, 8:59 AM

Thu, Feb 1

dim added a comment to D42702: Fix llvm-config --system-libs output on FreeBSD and NetBSD.

Hmm, apparently CMake *always* returns a full path for find_library(), but we seem to ignore those, by doing (for example in libclang's CMakeLists.txt):

Thu, Feb 1, 11:33 AM
dim added a comment to D42702: Fix llvm-config --system-libs output on FreeBSD and NetBSD.
In D42702#995106, @dim wrote:

-l/usr/lib/libexecinfo.so this should be replaced with -lexecinfo.

As I said, this is something detected by CMake, not LLVM's scripts. We could attempt to submit a fix to CMake, but that will take quite some time to arrive, and some vendor versions (such as Red Hat's or Debian's) will not be fixed for years, if ever.

This means that we need to implement check manually, in worst case hardcode it under the FreeBSD|NetBSD OS.

Thu, Feb 1, 10:40 AM
dim added a comment to D42702: Fix llvm-config --system-libs output on FreeBSD and NetBSD.

-l/usr/lib/libexecinfo.so this should be replaced with -lexecinfo.

Thu, Feb 1, 10:20 AM

Tue, Jan 30

dim created D42702: Fix llvm-config --system-libs output on FreeBSD and NetBSD.
Tue, Jan 30, 12:10 PM

Jan 20 2018

dim committed rL323041: Assume the shared library path variable is LD_LIBRARY_PATH on systems.
Assume the shared library path variable is LD_LIBRARY_PATH on systems
Jan 20 2018, 6:36 AM
dim committed rL323040: Assume the shared library path variable is LD_LIBRARY_PATH on systems.
Assume the shared library path variable is LD_LIBRARY_PATH on systems
Jan 20 2018, 6:36 AM
dim committed rCTE323040: Assume the shared library path variable is LD_LIBRARY_PATH on systems.
Assume the shared library path variable is LD_LIBRARY_PATH on systems
Jan 20 2018, 6:36 AM
dim committed rL323038: Merging r322875:.
Merging r322875:
Jan 20 2018, 4:23 AM
dim committed rL323037: Merging r322869:.
Merging r322869:
Jan 20 2018, 4:19 AM

Jan 18 2018

dim committed rL322879: Follow-up to rL322875 by initializing the do_libcxxabi variable properly..
Follow-up to rL322875 by initializing the do_libcxxabi variable properly.
Jan 18 2018, 11:33 AM
dim committed rL322875: Add a -no-libcxxabi option to the test-release.sh script..
Add a -no-libcxxabi option to the test-release.sh script.
Jan 18 2018, 10:42 AM
dim committed rL322869: Sprinkle a few <cstdlib> includes, for libomptarget sources using.
Sprinkle a few <cstdlib> includes, for libomptarget sources using
Jan 18 2018, 10:27 AM
dim committed rOMP322869: Sprinkle a few <cstdlib> includes, for libomptarget sources using.
Sprinkle a few <cstdlib> includes, for libomptarget sources using
Jan 18 2018, 10:27 AM

Jan 16 2018

dim accepted D42102: [X86] Allow usage of prefixes as a separate instr.

LGTM, works for all my test cases.

Jan 16 2018, 2:24 PM

Jan 13 2018

dim closed D41635: Align SHT_NOBITS sections is they are the first on a PT_LOAD.

This has been committed as rL321657, closing.

Jan 13 2018, 10:48 AM

Jan 12 2018

dim added inline comments to D41642: lib Fuzzer FreeBSD support.
Jan 12 2018, 10:38 AM

Jan 11 2018

dim added a comment to D41913: [LV] Don't call recordVectorLoopValueForInductionCast for newly-created IV from a trunc..

This looks good to me, but it's probably a good idea to let Dorit have a look as well. Also, this should be a release blocker if it's not already. Thanks!

Jan 11 2018, 1:10 PM
dim added a comment to D41913: [LV] Don't call recordVectorLoopValueForInductionCast for newly-created IV from a trunc..

For me, this fixes both minimized test cases mentioned in PR35773, and the full test cases originating from https://bugs.freebsd.org/224867 and https://bugs.freebsd.org/224868.

Jan 11 2018, 7:23 AM
dim committed rLLD322264: Fix thread race between SectionPiece's OutputOff and Live members.
Fix thread race between SectionPiece's OutputOff and Live members
Jan 11 2018, 12:04 AM
dim committed rL322264: Fix thread race between SectionPiece's OutputOff and Live members.
Fix thread race between SectionPiece's OutputOff and Live members
Jan 11 2018, 12:04 AM
dim closed D41884: Fix thread race between SectionPiece's OutputOff and Live members.
Jan 11 2018, 12:04 AM

Jan 9 2018

dim created D41884: Fix thread race between SectionPiece's OutputOff and Live members.
Jan 9 2018, 2:53 PM

Jan 7 2018

dim committed rL321963: Add pre-C++11 is_constructible wrappers for 3 arguments.
Add pre-C++11 is_constructible wrappers for 3 arguments
Jan 7 2018, 8:46 AM
dim committed rCXX321963: Add pre-C++11 is_constructible wrappers for 3 arguments.
Add pre-C++11 is_constructible wrappers for 3 arguments
Jan 7 2018, 8:46 AM
dim closed D41805: Add pre-C++11 is_constructible wrappers for 3 arguments.
Jan 7 2018, 8:46 AM

Jan 6 2018

dim created D41805: Add pre-C++11 is_constructible wrappers for 3 arguments.
Jan 6 2018, 5:25 PM

Jan 1 2018

dim accepted D41635: Align SHT_NOBITS sections is they are the first on a PT_LOAD.

For me, this works fine. Further reviews would be appreciated :)

Jan 1 2018, 2:41 PM

Dec 29 2017

dim added a comment to D41635: Align SHT_NOBITS sections is they are the first on a PT_LOAD.

It looks like GNU bfd/elf.c looks at the MemSiz field in the program header, then adds that to PhysAddr to get the end address of the segment (see line 5541 in bfd/elf.c). In case of .init_array, .fini_array, .data.rel.ro and .preinit_array, the load address is before the end of the address, and that causes it to complain:

$ readelf -lSW /usr/obj/share/dim/src/freebsd/clang600-import/amd64.amd64/sys/GENERIC/kernel.full
There are 68 section headers, starting at offset 0x642dc08:
Dec 29 2017, 4:49 PM
dim added a comment to D41635: Align SHT_NOBITS sections is they are the first on a PT_LOAD.

This makes libelf (and thus ctfmerge and elftoolchain objcopy) accept the lld-linked kernel, and building succeeds. GNU objcopy still shows that it is adjusting sections:

$ /usr/local/bin/objcopy /usr/obj/share/dim/src/freebsd/clang600-import/amd64.amd64/sys/GENERIC/kernel.full kernel.test
/usr/local/bin/objcopy: kernel.test: section .init_array lma 0x1734000 adjusted to 0x17340f0
/usr/local/bin/objcopy: kernel.test: section .fini_array lma 0x1734000 adjusted to 0x17340f0
/usr/local/bin/objcopy: kernel.test: section .data.rel.ro lma 0x1734000 adjusted to 0x17340f0
/usr/local/bin/objcopy: kernel.test: section .preinit_array lma 0x1734000 adjusted to 0x17340f0

However, that may be some quirk of GNU binutils's ELF handling...

Dec 29 2017, 3:26 PM

Dec 28 2017

dim committed rL321545: Avoid modifying DbgInfo while looping in salvageDebuginfo.
Avoid modifying DbgInfo while looping in salvageDebuginfo
Dec 28 2017, 3:43 PM
dim closed D41589: Avoid modifying DbgInfo while looping in salvageDebuginfo.
Dec 28 2017, 3:43 PM

Dec 26 2017

dim created D41589: Avoid modifying DbgInfo while looping in salvageDebuginfo.
Dec 26 2017, 4:16 PM
dim accepted D41579: [X86] A fix for pr35741 - can't use comments with instr prefixes.

Works for me too.

Dec 26 2017, 7:39 AM

Dec 24 2017

dim committed rCRT321431: Fix PR35739: chkstk and chkst2 should only be built for Windows.
Fix PR35739: chkstk and chkst2 should only be built for Windows
Dec 24 2017, 1:16 PM
dim committed rL321431: Fix PR35739: chkstk and chkst2 should only be built for Windows.
Fix PR35739: chkstk and chkst2 should only be built for Windows
Dec 24 2017, 1:12 PM
dim closed D41567: Add NO_EXEC_STACK_DIRECTIVE to chkstk and chkstk2 sources.
Dec 24 2017, 1:12 PM
dim added a comment to D41567: Add NO_EXEC_STACK_DIRECTIVE to chkstk and chkstk2 sources.

hmm looking at the #define for NO_EXEC_STACK_DIRECTIVE
once the two files have been removed from non windows targets they won't do anything anymore.

Dec 24 2017, 12:59 PM
dim updated the diff for D41567: Add NO_EXEC_STACK_DIRECTIVE to chkstk and chkstk2 sources.

Oops, checked in wrong revision. This has both fixes:

  • Add NO_EXEC_STACK_DIRECTIVE, that can never hurt
  • Remove chkstk*.S from non-Windows targets
Dec 24 2017, 12:38 PM
dim updated the diff for D41567: Add NO_EXEC_STACK_DIRECTIVE to chkstk and chkstk2 sources.

Do not build chkstk.S and chkstk2.S for non-Windows targets.

Dec 24 2017, 12:36 PM
dim created D41567: Add NO_EXEC_STACK_DIRECTIVE to chkstk and chkstk2 sources.
Dec 24 2017, 11:53 AM
dim added a comment to D41512: [Sema] -Wtautological-constant-compare is too good. Cripple it..

Actually, having thought about it a little more, if the warning is "rather broken", or even "completely broken", depending on one's point of view, then maybe it is better not have it under -Wextra either? E.g. somebody has to ask for the warning specifically, using -Wtautological-constant-compare, or use -Weverything?

Dec 24 2017, 8:45 AM · Restricted Project
dim accepted D41512: [Sema] -Wtautological-constant-compare is too good. Cripple it..

Yes, please. Rather sooner than later, the warning itself can be fixed post-6.0.0.

Dec 24 2017, 7:49 AM · Restricted Project

Dec 19 2017

dim added a comment to D41057: Avoid a gnu readelf warning.

Let's indeed drop this, since upstream readelf has been fixed.

Dec 19 2017, 10:33 AM

Dec 18 2017

dim committed rOMP321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:55 AM
dim committed rLLD321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:48 AM
dim committed rCTE321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:48 AM
dim committed rC321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:48 AM
dim committed rCRT321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:47 AM
dim committed rL321016: Fix more inconsistent line endings. NFC..
Fix more inconsistent line endings. NFC.
Dec 18 2017, 11:47 AM
dim committed rL321009: Fix inconsistent line endings in HexagonVectorLoopCarriedReuse.cpp. NFC..
Fix inconsistent line endings in HexagonVectorLoopCarriedReuse.cpp. NFC.
Dec 18 2017, 10:56 AM
dim committed rL321006: Fix inconsistent line endings in ARCDisassembler.cpp. NFC..
Fix inconsistent line endings in ARCDisassembler.cpp. NFC.
Dec 18 2017, 10:46 AM

Dec 14 2017

dim committed rL320755: Don't trigger -Wuser-defined-literals for system headers.
Don't trigger -Wuser-defined-literals for system headers
Dec 14 2017, 2:33 PM
dim committed rC320755: Don't trigger -Wuser-defined-literals for system headers.
Don't trigger -Wuser-defined-literals for system headers
Dec 14 2017, 2:33 PM
dim closed D41080: Don't trigger -Wuser-defined-literals for system headers.
Dec 14 2017, 2:33 PM

Dec 11 2017

dim updated the diff for D41080: Don't trigger -Wuser-defined-literals for system headers.

Add a test case.

Dec 11 2017, 1:33 PM
dim abandoned D41064: Suppress -Wuser-defined-literals for <string> and <string_view>.

Abandoned in favor of D41080.

Dec 11 2017, 11:12 AM
dim created D41080: Don't trigger -Wuser-defined-literals for system headers.
Dec 11 2017, 11:12 AM
dim updated the diff for D41064: Suppress -Wuser-defined-literals for <string> and <string_view>.

Updated to also include <chrono> and <complex>. I think all cases are
covered now.

Dec 11 2017, 10:11 AM
dim created D41064: Suppress -Wuser-defined-literals for <string> and <string_view>.
Dec 11 2017, 4:37 AM

Dec 10 2017

dim added a comment to D41037: Create reserved symbols early so they can be versioned.

When I patch lld trunk rL320307 with this, executables linked by it make readelf (from binutils 2.28) produce a warning:

readelf: Warning: [10]: Info field (0) should index a relocatable section.

And I still don't see any _end symbol in the executable.

Dec 10 2017, 8:37 AM

Dec 8 2017

dim accepted D41016: [Sema] Fix crash in unused-lambda-capture warning for VLAs.

For the rest, LGTM. It fixes the segfault, for both the full original test case, and my reduced version.

Dec 8 2017, 11:25 AM

Oct 26 2017

dim accepted D39297: [DynamicLibrary] Fix build on musl libc.

LGTM.

Oct 26 2017, 3:40 AM