History log of /llvm-project/llvm/tools/llvm-exegesis/lib/SubprocessMemory.cpp (Results 1 – 19 of 19)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4
# fac87b88 27-Aug-2024 Aiden Grossman <aidengrossman@google.com>

[llvm-exegesis] Switch from intptr_t to uintptr_t in most cases (#102860)

This patch switches most of the uses of intptr_t to uintptr_t within
llvm-exegesis for the subprocess memory support. In th

[llvm-exegesis] Switch from intptr_t to uintptr_t in most cases (#102860)

This patch switches most of the uses of intptr_t to uintptr_t within
llvm-exegesis for the subprocess memory support. In the vast majority of
cases we do not want a signed component of the address, hence making
intptr_t undesirable. intptr_t is left for error handling, for example
when making syscalls and we need to see if the syscall returned -1.

show more ...


Revision tags: llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5
# ad2816e7 26-Apr-2024 Aiden Grossman <aidengrossman@google.com>

[llvm-exegesis] Use const reference for range variable

In the SubprocessMemory destructor, I was using a normal std::string to
hold the name of the current shared memory name, but a const reference

[llvm-exegesis] Use const reference for range variable

In the SubprocessMemory destructor, I was using a normal std::string to
hold the name of the current shared memory name, but a const reference
works just as well in this situation while having better performance
characteristics.

Fixes #90289

show more ...


# 74a5e778 26-Apr-2024 Aiden Grossman <aidengrossman@google.com>

[llvm-exegesis] Close file descriptors after use (#86584)

There are several insstances in the subprocess executor in llvm-exegesis
where we fail to close file descriptors after using them. This lea

[llvm-exegesis] Close file descriptors after use (#86584)

There are several insstances in the subprocess executor in llvm-exegesis
where we fail to close file descriptors after using them. This leaves
them open, which can cause issues later on if a third-party binary is
using the exegesis libraries and executing many blocks before exiting.
Leaving the descriptors open until process exit is also bad practice.
This patch fixes that by explicitly calling close() when we are done
with a specific file descriptor.

This patch fixes #86583.

show more ...


# 61f40016 18-Apr-2024 Aiden Grossman <aidengrossman@google.com>

[llvm-exegesis] Define SYS_gettid if not available

This patch defines SYS_gettid as __NR_gettid if SYS_gettid is not
available to avoid compile time errors due to SYS_gettid not being
defined. This

[llvm-exegesis] Define SYS_gettid if not available

This patch defines SYS_gettid as __NR_gettid if SYS_gettid is not
available to avoid compile time errors due to SYS_gettid not being
defined. This happens with certain libcs (like bionic) that do not
define SYS_gettid.

show more ...


Revision tags: llvmorg-18.1.4
# a29e85d6 16-Apr-2024 Aiden Grossman <aidengrossman@google.com>

[llvm-exegesis] Change preprocessor directives for getCurrentTID

This patch changes the preprocessor directives surrounding
getCurrentTID, particularly moving it out of the block that is only
define

[llvm-exegesis] Change preprocessor directives for getCurrentTID

This patch changes the preprocessor directives surrounding
getCurrentTID, particularly moving it out of the block that is only
defined when not building for Android. The getCurrentTID function is
called in places that only require Linux definitions, so this function
should have the same preprocessor scoping around it to prevent link time
failures.

show more ...


Revision tags: llvmorg-18.1.3
# fa90a0aa 27-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Improve error handling for shm_open calls

This patch adds error handling for shm_open failures in one case where
they were not handled before and also makes an error handler in anoth

[llvm-exegesis] Improve error handling for shm_open calls

This patch adds error handling for shm_open failures in one case where
they were not handled before and also makes an error handler in another
case report the value of errno for diagnosis.

show more ...


# 50e62181 22-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit 1fe9c417a0bf143f9bb9f9e1fbf7b20f44196883.

This relands commit 6bbe8a296ee91754d423c59c35727eaa624f714

Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit 1fe9c417a0bf143f9bb9f9e1fbf7b20f44196883.

This relands commit 6bbe8a296ee91754d423c59c35727eaa624f7140.

This was causing build failures on one of the ARMv8 builders. Still not
completely sure why, but relanding it to see if the failure pops up
again. If it does, the plan is to fix forward by disabling tests on ARM
temporarily as llvm-exegesis does not currently use SubprocessMemory
on ARM.

show more ...


Revision tags: llvmorg-18.1.2
# 1fe9c417 13-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

Revert "Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)""

This reverts commit 8003f553a01a9a2a7eb09fe07e88f1ba9ee7d3a7.

This (and/or a related commit) was causing build f

Revert "Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)""

This reverts commit 8003f553a01a9a2a7eb09fe07e88f1ba9ee7d3a7.

This (and/or a related commit) was causing build failures on one of the
buildbots that needs more investigation. More information is available
at https://lab.llvm.org/buildbot/#/builders/178/builds/7015.

show more ...


# 5a4e2210 13-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

Revert "[llvm-exegesis] Use LLVM Support to get thread ID"

This reverts commit 1c3b15e9f5bc671e40bcf5d3475f5425466754ce.

This (and/or) a related patch was causing build failures on one of the
build

Revert "[llvm-exegesis] Use LLVM Support to get thread ID"

This reverts commit 1c3b15e9f5bc671e40bcf5d3475f5425466754ce.

This (and/or) a related patch was causing build failures on one of the
buildbots. More information is available at
https://lab.llvm.org/buildbot/#/builders/178/builds/7015.

show more ...


# 1c3b15e9 12-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Use LLVM Support to get thread ID

This patch switches from manually using the Linux syscall to get the
current thread ID to using the relevant LLVM Support libraries that
abstract ov

[llvm-exegesis] Use LLVM Support to get thread ID

This patch switches from manually using the Linux syscall to get the
current thread ID to using the relevant LLVM Support libraries that
abstract over the low level system details.

show more ...


# 8003f553 12-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit aefad27096bba513f06162fac2763089578f3de4.

This relands commit 6bbe8a296ee91754d423c59c35727eaa624f714

Reland "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit aefad27096bba513f06162fac2763089578f3de4.

This relands commit 6bbe8a296ee91754d423c59c35727eaa624f7140.

This patch was casuing build failures on non-Linux platforms due to the
default implementations for the functions not being updated. This ended
up causing out-of-line definition errors. Fixed for the relanding.

show more ...


# aefad270 12-Mar-2024 Florian Hahn <flo@fhahn.com>

Revert "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit 6bbe8a296ee91754d423c59c35727eaa624f7140.

This breaks building LLVM on macOS, failing with

llvm/

Revert "[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)"

This reverts commit 6bbe8a296ee91754d423c59c35727eaa624f7140.

This breaks building LLVM on macOS, failing with

llvm/tools/llvm-exegesis/lib/SubprocessMemory.cpp:146:33: error: out-of-line definition of 'setupAuxiliaryMemoryInSubprocess' does not match any declaration in 'llvm::exegesis::SubprocessMemory'
Expected<int> SubprocessMemory::setupAuxiliaryMemoryInSubprocess(

show more ...


# 6bbe8a29 12-Mar-2024 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)

This patch adds the thread ID to the subprocess memory shared memory
names. This avoids conflicts for downstream consumers that mi

[llvm-exegesis] Add thread IDs to subprocess memory names (#84451)

This patch adds the thread ID to the subprocess memory shared memory
names. This avoids conflicts for downstream consumers that might want to
consume llvm-exegesis across multiple threads, which would otherwise run
into conflicts due to the same PID running multiple instances.

show more ...


Revision tags: llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init
# e1b88a97 09-Jul-2023 Christopher Di Bella <cjdb.ns@gmail.com>

[llvm-exegesis][NFC] imports `<cerrno>`

`SubprocessMemory.cpp` depends on `errno` and was likely getting it via
a transitive include, but this prevents building with modules.


# 71cbc62a 07-Jul-2023 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Disable SubprocessMemory class on Android

Having the SubprocessMemory class available on Android was causing build
failures in downstream builds as Android doesn't implement the Syst

[llvm-exegesis] Disable SubprocessMemory class on Android

Having the SubprocessMemory class available on Android was causing build
failures in downstream builds as Android doesn't implement the SystemV
IPC specification that supplies shm_open and other functions that the
class relies on. This patch simply makes it unavailable on Android using
preprocessor directives.

show more ...


# 1048b7f8 30-Jun-2023 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Make sure auxiliary memory is unlinked after usage

Currently the shm_unlink is never called on the auxiliary memory shared
memory, so it stays around after running llvm-exegesis (inc

[llvm-exegesis] Make sure auxiliary memory is unlinked after usage

Currently the shm_unlink is never called on the auxiliary memory shared
memory, so it stays around after running llvm-exegesis (including
running the llvm-exegesis tests). This patch adds the auxiliary memory
shared memory name to the SharedMemoryNames list so that it gets
unlinked when the destructor of SubprocessMemory is called.

show more ...


Revision tags: llvmorg-16.0.6, llvmorg-16.0.5
# 5a63b2b3 20-May-2023 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory to
set up an execution environment for memory annotations.

Reviewed By: courbet

Differential Revision: https://reviews.llvm.org/D151022

show more ...


# 0b6b400b 20-May-2023 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory to
set up an execution environment for memory annotations.

Reviewed By: courbet

Differential Revision: https://reviews.llvm.org/D151022

show more ...


# 1b9b78fd 20-May-2023 Aiden Grossman <agrossman154@yahoo.com>

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory

[llvm-exegesis] Introduce SubprocessMemory Utility Class

This patch introduces the SubprocessMemory class to llvm-exegesis. This
class contains several utilities that are needed for managing memory to
set up an execution environment for memory annotations.

Reviewed By: courbet

Differential Revision: https://reviews.llvm.org/D151022

show more ...