15 months agoMove architecture dependent code in PCWidget.C to three separate architecture specifi...
Xiaozhu Meng [Tue, 23 Apr 2019 19:17:23 +0000 (14:17 -0500)]
Move architecture dependent code in PCWidget.C to three separate architecture specific source files.

15 months agoFor jump table analysis, control flow edges can be created in different orders,
Xiaozhu Meng [Tue, 23 Apr 2019 14:02:39 +0000 (09:02 -0500)]
For jump table analysis, control flow edges can be created in different orders,
which lead to non-deterministic slicing and non-determinisitc jump table analysis.

Therefore, we need to sort source edges in slicing based on the edge's source block
address and edge type to ensure deterministic slicing.

15 months ago1. Replace springboards prioriy "OffLimits" and "Required" with "FuncEntry" and ...
Xiaozhu Meng [Thu, 18 Apr 2019 16:16:06 +0000 (11:16 -0500)]
1. Replace springboards prioriy "OffLimits" and "Required" with "FuncEntry" and "IndirBlockEntry".

Only "FuncEntry" springboards are required because control flow enter instrumentation
through function calls (we relocate the whole function even if only a part of the
function is instrumented).

"IndirBlockEntry" springboards are important for re-directing control flow from
jump tables back to instrumentation. But, it is not as important as "FuncEntry".

2. Jumps to code in another secion should be treated as tail calls.

15 months agoIn dynamic instrumentation, springboards are installed immediately after
Xiaozhu Meng [Sun, 14 Apr 2019 22:00:48 +0000 (17:00 -0500)]
In dynamic instrumentation, springboards are installed immediately after
users insert a snippet. The user can continue to insert more snippets to
the same function, which will trigger Dyninst to perform the additional
relocation. So, we need to overwrite existing springboard for newly added

In other words, we need to overwrite existing springboards if the existing
ones were installed in previous relocations.

15 months agoDelete unnecessary asserts
Xiaozhu Meng [Fri, 12 Apr 2019 21:38:44 +0000 (16:38 -0500)]
Delete unnecessary asserts

15 months agoThe _func_cnt member variable in class ParseAPI::Block should be atomic<int>,
Xiaozhu Meng [Fri, 12 Apr 2019 21:13:42 +0000 (16:13 -0500)]
The _func_cnt member variable in class ParseAPI::Block should be atomic<int>,
rather than just int. A block can be shared by multiple functions. So, when
multiple functions add/remove blocks at the same time, there will be race conditions.

15 months agoFix compilation error introduced during applying patches
Xiaozhu Meng [Fri, 12 Apr 2019 20:33:34 +0000 (15:33 -0500)]
Fix compilation error introduced during applying patches

15 months agoCorrectness fixes for springboard generators
Benjamin Welton [Wed, 13 Feb 2019 23:13:39 +0000 (17:13 -0600)]
Correctness fixes for springboard generators

This patch deals with issues where incorrect springboards could be generated.
Specifically addresses three issues:

1. Springboards trampling function data (addresses github issue #551)

2. Required springboards being spilling over block bounds onto
   other required springboards. Prior a if two required springboards were
   located near each other, there was a chance that one of the springboards
   could be partially overwritten resulting in broken behavior.

3. Unsafe reusage of a codegen object where if a trap was needed,
   both a branch and a trap would be written causing bad behavior.

15 months agoFix finding the trap mapping header in .dyninstInst
Xiaozhu Meng [Thu, 4 Apr 2019 17:55:23 +0000 (12:55 -0500)]
Fix finding the trap mapping header in .dyninstInst

DT_DYNINST entry of the .dynamic section points the memory offset of
the trap mapping header. Should use this information to locate
trap mapping table when adjusting trap mapping entries for PIC code

15 months ago1. If ParseAPI identifies a jump as a tail call, but later find that this jump is...
Xiaozhu Meng [Wed, 3 Apr 2019 23:04:14 +0000 (18:04 -0500)]
1. If ParseAPI identifies a jump as a tail call, but later find that this jump is the only incoming edge of the targXXX function, we should not treat this jump as a tail call.

In theory, it is reasonable either way. However, treating such jump
as a tail call can cause troubles for function entry instrumentation.
If the targXXX function may jump back to the original function, and
thus reach the tail jump. This becomes a recursive tail call.

However, Dyninst relocation seems to have problem adjusting the tail jump
to include entry instrumentation.

2. If the determination of a tail call is changed, we should re-compute
function boundaries, including ret blocks, exit blocks, call edges

15 months agoFix warnings on adjusting trap springboards
Xiaozhu Meng [Tue, 2 Apr 2019 20:27:40 +0000 (15:27 -0500)]
Fix warnings on adjusting trap springboards

15 months agoFix springboard traps for PIC code
Xiaozhu Meng [Tue, 2 Apr 2019 19:00:43 +0000 (14:00 -0500)]
Fix springboard traps for PIC code

15 months agoFix the problem where trap springboards are not written to the mutatee.
Xiaozhu Meng [Mon, 1 Apr 2019 23:36:03 +0000 (18:36 -0500)]
Fix the problem where trap springboards are not written to the mutatee.

16 months agoConvert ThreadDB error message to info message (#574)
Tim Haines [Thu, 28 Mar 2019 21:11:58 +0000 (16:11 -0500)]
Convert ThreadDB error message to info message (#574)

By default, the cmake 'message' command generates an error message. This converts it to an informational message.

16 months agoA few fixes for parallel parsing (#572)
Xiaozhu Meng [Thu, 28 Mar 2019 21:04:40 +0000 (16:04 -0500)]
A few fixes for parallel parsing (#572)

1. Fix a scenario where the delayed work of call ft edges may be skipped
2. Augment indirect jump target check, so that if a jump target is decoded
   to be No_Entry, we treat this jump target invalid
3. Should only re-parse jump tables (not indirect tail calls) for fixed point

On ppple, spring boards may need to be long branch (can be more than 5
instructions). Allocate enough space in codegen for long branch spring boards.

16 months agoShould set errno to zero before calling ptrace (#569)
Xiaozhu Meng [Tue, 26 Mar 2019 17:53:54 +0000 (12:53 -0500)]
Should set errno to zero before calling ptrace (#569)

16 months agoImplement ARMv8 IMFC and Load/Store Shared (#562)
L.E.R [Tue, 12 Mar 2019 17:59:45 +0000 (12:59 -0500)]
Implement ARMv8 IMFC and Load/Store Shared (#562)

* Implement AArch64 InterModule Function call
* fix memory access mistakes, now uses offset mode
* removed all the debug printout for imfc
* add rewriter mode check- delete unwanted functions
* fix break on dynamic mode
* aarch64 broken movePCToReg implementation
* movePCToReg still not working
* fix addressing mode for emitLoadRelative
* LoadShared: snip_ref_shlib_var test passes
* add assert details, remove debug code, and format patch
* inst-aarch64: sprintf -> snprintf, debug comments cleanup
* Minor cleanup- Remove commented-out code and debug print statements.

16 months agoFix ARM stack walking (#559)
Xiaozhu Meng [Tue, 12 Mar 2019 18:43:33 +0000 (13:43 -0500)]
Fix ARM stack walking (#559)

16 months agoFix unnecessary multiple calls to buildSysRegMap.
Sasha @leela [Fri, 15 Feb 2019 01:14:29 +0000 (19:14 -0600)]
Fix unnecessary multiple calls to buildSysRegMap.

This function should be called only once, but was being called for every
instruction to be decoded. As a result, dyninst would take a long time
to execute. Now to simply run test1_1 on create mode takes 28 seconds,
as opposed to 58 before this fix, and now closer to 20 seconds for x86_64.

17 months agoAttempts to fix legacy test failures in Dyninst test suite (#549)
Xiaozhu Meng [Thu, 7 Mar 2019 00:08:22 +0000 (18:08 -0600)]
Attempts to fix legacy test failures in Dyninst test suite (#549)

* In binary rewriting, when Dyninst needs to load a library,
    it does not check whether this library has been loaded before or not.
    Dyninst will create multiple binaryEdit objects for one library, which can cause inconsistent states between these objects.

    This fix adds a map to BPatch_binaryEdit to make sure each library is only loaded once.

* Fix pc_tls failures in dyamically linked binaries.
    The root cause is a broken library name matching code.
    Just should boost:filesystem::path to deal with file paths.

Closes #549

17 months agoFix tests in PIC mode (#553)
Xiaozhu Meng [Thu, 7 Mar 2019 00:06:54 +0000 (18:06 -0600)]
Fix tests in PIC mode (#553)

* In dynamic instrumentation for PIE, finding variables's locations needs to add the load base of the PIE.
    Get rid of wrong, special handling of finding the load base of PIE.
* On x86-64, when emulating call with push & jmp, the push needs to push all 64-bit of the callee addresses.
* A few fixes for PIC instrumentation on power
    1. Fix PC-relative load and store of variables
    2. The preamble of PIE uses R12 to set up R2. However,
    when generating intra-module calls, Dyninst does not
    set up R12 and will call the global entry, causing R2 to
    be incorrect. Since there is no need to change R2 for
    intra-module calls, we should call the local entry
* Fix function call replacment on power for PIC.
    Need to call local entry when doing an intra-module call
* Handle relocation type R_X86_64_REX_GOTPCRELX for binary rewriting of statically linked binaries on x86-64
* Fix endianess issues for generating _init and _fini functions on power

17 months agoElfutil version check (#558)
Tim Haines [Thu, 7 Mar 2019 00:04:05 +0000 (18:04 -0600)]
Elfutil version check (#558)

* Add Ubuntu locations
* Search for libelf.so instead of libelf.so.1
    This makes the likelihood of find a symlink more probable.
* Add version checking
    find_package_handle_standard_args doesn't check versions of shared
    libraries, so we need to do it manually.
* Always make the configuration for elfutils noisy

17 months agoAdd --enable-install-elfh when building elfutils from source (#555)
Tim Haines [Thu, 7 Mar 2019 00:03:38 +0000 (18:03 -0600)]
Add --enable-install-elfh when building elfutils from source (#555)

When building elfutils from source on systems that have old elfutils,
Dyninst couldn't find the correct version of elf.h due to it not
being copied from the elfutils build source directory to the include
directory. In the Feb 15 2019 release of elfutils, this flag was
added to fix this.

17 months agoFix separate debuginfo
Sasha Nicolas [Tue, 12 Feb 2019 23:44:30 +0000 (17:44 -0600)]
Fix separate debuginfo
Adding correct FrameFarser to static map
Parsing modules of correct debug file

17 months agoRevert the change from PR530 that will cause crashes in rewriting
Xiaozhu Meng [Fri, 8 Feb 2019 22:19:37 +0000 (16:19 -0600)]
Revert the change from PR530 that will cause crashes in rewriting
statically linked binaries.

17 months agoMerge pull request #548 from dyninst/dynsym_fix
Xiaozhu Meng [Fri, 8 Feb 2019 21:15:11 +0000 (15:15 -0600)]
Merge pull request #548 from dyninst/dynsym_fix

Do not put newly added functions to .dynsym, which may cause the load

18 months agoRemove undefined behavior from bit-shifting code
Tim Haines [Thu, 7 Feb 2019 22:33:13 +0000 (16:33 -0600)]
Remove undefined behavior from bit-shifting code

PR #536

Overflow of signed integer arithmetic (including shifting) is
undefined behavior in C++. Compilers are allowed to exploit
this UB for optimization purposes up to and including not
emitting any opcodes.

These were found using cppcheck.

18 months agoDo not put newly added functions to .dynsym, which may cause the load 548/head
Xiaozhu Meng [Wed, 6 Feb 2019 22:16:16 +0000 (16:16 -0600)]
Do not put newly added functions to .dynsym, which may cause the load
to behave abnormally due to duplicated symbols.

Note that adding symbols to .dynsym can be a legit use case, where
we expose hidden functions in shared libraries. But this use case
needs more development to support.

18 months agoMerge pull request #543 from dyninst/ppcle_rhel8_fix
Xiaozhu Meng [Wed, 6 Feb 2019 22:07:01 +0000 (16:07 -0600)]
Merge pull request #543 from dyninst/ppcle_rhel8_fix

Ppcle rhel8 fix

18 months agoFix several bugs in common/src/pathName.C
Tim Haines [Tue, 5 Feb 2019 19:31:10 +0000 (13:31 -0600)]
Fix several bugs in common/src/pathName.C

1. Tilde expansion is done _before_ the existence check.
Since `stat` does not do shell expansions, resolve_file_path("~")
    always returned an empty string instead of the expanded path.

2. Tilde detection logic was inverted

3. Remove possible buffer overflow when making path relative to CWD

ADDED features:

1. Removes leading and trailing whitespace

2. Add basic support for Windows file system by using Boost::filesystem
Expansion of Windows-specific shell variables, e.g. %HOME%, is _not_

3. Leverage move semantics to reduce copying
This reduces the maximum number of string copies from 5 to 3. When
resolve_file_path is invoked with an r-value, there are only two

18 months agoAdjust Dyninst to support injecting CFGs for CUBINs
Keren Zhou [Mon, 4 Feb 2019 19:17:52 +0000 (13:17 -0600)]
Adjust Dyninst to support injecting CFGs for CUBINs

See PR #530 for details.

18 months agoAdd some explicit casts from boost::tribool to bool for some code in (#541)
Mark W. Krentel [Fri, 1 Feb 2019 19:14:11 +0000 (13:14 -0600)]
Add some explicit casts from boost::tribool to bool for some code in (#541)

Add some explicit casts from boost::tribool to bool for some code in dataflowAPI/rose/util/Message.[Ch].  This was breaking the build when using boost >= 1.69.

18 months agoDo not generate new PLTs for IFUNC when rewriting statically linked 543/head
Xiaozhu Meng [Wed, 30 Jan 2019 20:53:08 +0000 (14:53 -0600)]
Do not generate new PLTs for IFUNC when rewriting statically linked
binaries on x86. IFUNC should be handled by the loader, not the
linker, which is Dyninst when rewriting statically linked binaries.

18 months agoMore fixes on ppcle rewriting of statically linked binaries
Xiaozhu Meng [Wed, 30 Jan 2019 19:46:16 +0000 (19:46 +0000)]
More fixes on ppcle rewriting of statically linked binaries

1. Revert the change made in "760bfda6e409b4b61a6acd093548afa5860b4af1" about undefined symbols.
Section with number 0 is NULL section, not .bss. So, symbols with section number 0 are indeed
undefined symbols.
2. libc.a depends on libgcc.a on fedora 28 ppcle. So, also open libgcc.a to resolve undefined symbols.
3. Fix the handling of relocation entry "R_PPC64_REL24". R_PPC64_REL24 means the caller has set
up R2, so we should call the local entry point. Calling the global entry may lead to wrong r2, because
r12 is not properly set at the call site.
4. IFUNC should not be treated as a need for PLT.

18 months agoFix crash caused by erasing an iterator from a std::map while looping the iterator
Xiaozhu Meng [Tue, 29 Jan 2019 04:07:53 +0000 (04:07 +0000)]
Fix crash caused by erasing an iterator from a std::map while looping the iterator

18 months agoA couple fixes for binary rewriting of statically linked binaries on ppcle
Xiaozhu Meng [Tue, 29 Jan 2019 00:38:39 +0000 (00:38 +0000)]
A couple fixes for binary rewriting of statically linked binaries on ppcle

1. The handling of the libc global constructor and destructor is out-of-date. Follow the handling for x86-64.
2. Replace [] operator with insert() for std::map. [] operator caused weird memory corruptions
3. Symbols defined in .bss sections should not be considered undefined symbosl
4. Add and fix handling for a couple of ppc64 relocation entries

18 months agoThese functions were moved to the Emitter class.
Sasha Nicolas [Thu, 24 Jan 2019 18:09:35 +0000 (12:09 -0600)]
These functions were moved to the Emitter class.

18 months agoMerge pull request #537 from hainest/remove_ci
Tim Haines [Thu, 24 Jan 2019 17:02:57 +0000 (11:02 -0600)]
Merge pull request #537 from hainest/remove_ci

Remove Travis and AppVeyor CI

18 months agoMerge pull request #539 from hainest/gitignore_eclipse
Tim Haines [Thu, 24 Jan 2019 16:59:19 +0000 (10:59 -0600)]
Merge pull request #539 from hainest/gitignore_eclipse

Ignore Eclipse settings files and folders

18 months agoIgnore Eclipse settings files and folders 539/head
Tim Haines [Thu, 24 Jan 2019 15:42:56 +0000 (09:42 -0600)]
Ignore Eclipse settings files and folders

18 months agoRemove Travis and AppVeyor CI 537/head
Tim Haines [Wed, 23 Jan 2019 23:31:16 +0000 (17:31 -0600)]
Remove Travis and AppVeyor CI

This will be replaced with the Gitlab CI

18 months agofix missing installation of libdw when installing elfutils
rafzi [Tue, 22 Jan 2019 14:23:41 +0000 (15:23 +0100)]
fix missing installation of libdw when installing elfutils

18 months agoMerge branch 'fix_elf_h'
Sasha @leela [Tue, 15 Jan 2019 23:42:59 +0000 (17:42 -0600)]
Merge branch 'fix_elf_h'

18 months agoMerge pull request #516 from jmellorcrummey/fix-linemap
Xiaozhu Meng [Tue, 15 Jan 2019 21:11:57 +0000 (15:11 -0600)]
Merge pull request #516 from jmellorcrummey/fix-linemap

Fix linemaps for CUBINs

18 months agoMerge pull request #528 from dyninst/ppc_pc_fix
Xiaozhu Meng [Tue, 15 Jan 2019 20:29:09 +0000 (14:29 -0600)]
Merge pull request #528 from dyninst/ppc_pc_fix

Ppc pc fix

18 months agoMerge pull request #518 from stanfordcox/scox/includes
Xiaozhu Meng [Tue, 15 Jan 2019 19:13:42 +0000 (13:13 -0600)]
Merge pull request #518 from stanfordcox/scox/includes

Don't use system header <> syntax for dyninst includes

18 months agoRemove asserts that cause test failures 528/head
Xiaozhu Meng [Tue, 15 Jan 2019 16:43:26 +0000 (10:43 -0600)]
Remove asserts that cause test failures

18 months agoFix a non-deterministic hang in test_thread_5
Xiaozhu Meng [Sat, 12 Jan 2019 20:05:12 +0000 (14:05 -0600)]
Fix a non-deterministic hang in test_thread_5

When the mutator stops the mutatee, the mutator will wait for
all the threads in the mutatee to stop by counting the number
of STOP events. If one of the thread exited, there will be no
STOP comeing back.

When a pre-exit event is handled, if the thread has pending stop
to be waited, we should no longer wait for this thread.

18 months agoMoving funtion emitElfUtils::updateRelocation to specific platform fix_elf_h
Sasha @leela [Fri, 11 Jan 2019 00:54:16 +0000 (18:54 -0600)]
Moving funtion emitElfUtils::updateRelocation to specific platform
files, since this function uses machine specific macros from elf.h

18 months agoMerge branch 'master' into ARMv8
Sasha @leela [Thu, 10 Jan 2019 22:21:31 +0000 (16:21 -0600)]
Merge branch 'master' into ARMv8

18 months agoMerge branch 'ARMv8' of https://github.com/dyninst/dyninst into ARMv8
Sasha @leela [Thu, 10 Jan 2019 22:19:47 +0000 (16:19 -0600)]
Merge branch 'ARMv8' of https://github.com/dyninst/dyninst into ARMv8

18 months agoRealized effective address calculation, but still need debugging as the result is...
Yuhan Xie [Thu, 10 Jan 2019 13:58:38 +0000 (07:58 -0600)]
Realized effective address calculation, but still need debugging as the result is not always correct.

18 months agoCleaned up power_opcode_table.C, revised several duplications.
Yuhan Xie [Thu, 10 Jan 2019 12:38:11 +0000 (06:38 -0600)]
Cleaned up power_opcode_table.C, revised several duplications.
Some old instructions was not deleted in the previous release, which would cause the new instructions with the same opcode futile.
All duplications has been revised but two special duos (mfocrf & mfcr, fcfids & fcfid)

19 months agoFix on x86-64 the mov instruction for register of 16-bit size.
Sasha Nicolas [Fri, 4 Jan 2019 00:22:50 +0000 (18:22 -0600)]
Fix on x86-64 the mov instruction for register of 16-bit size.
The opcode 89h is for both 32-bit and 16-bit but to use
the 16-bit version it's necessary to add an operand-size prefix
byte of value 66h.
Test snip_ref_shlib_var now passing on x86-64 linux.

19 months agoMerge branch 'ARMv8' of https://github.com/dyninst/dyninst into ARMv8
Sasha @leela [Fri, 28 Dec 2018 20:15:35 +0000 (14:15 -0600)]
Merge branch 'ARMv8' of https://github.com/dyninst/dyninst into ARMv8

19 months agoMerge branch 'master' into ARMv8
Sasha @leela [Fri, 28 Dec 2018 20:15:28 +0000 (14:15 -0600)]
Merge branch 'master' into ARMv8

19 months agofmt mixed-indented line changes to space-indented
LER0ever [Thu, 27 Dec 2018 06:49:50 +0000 (00:49 -0600)]
fmt mixed-indented line changes to space-indented

19 months agoimplement params ref for more than 8 args for AArch64
LER0ever [Thu, 27 Dec 2018 06:45:48 +0000 (00:45 -0600)]
implement params ref for more than 8 args for AArch64
test1_36 now passes on ARMv8

19 months agoGenerating Load and Store of 1, 2, 4 or 8 bytes
Sasha @leela [Sat, 22 Dec 2018 01:35:40 +0000 (19:35 -0600)]
Generating Load and Store of 1, 2, 4 or 8 bytes
for general purpose registers.
The function generateMemAccess32or64 has been renamed
to generateMemAccess, and the boolean parameter changed
to integer to hold the size of bytes to be loaded or
test_snip_ref_shlib_var passes.

19 months agoDeal with relocation type R_PPC64_IRELATIVE
Xiaozhu Meng [Thu, 20 Dec 2018 21:48:39 +0000 (15:48 -0600)]
Deal with relocation type R_PPC64_IRELATIVE

19 months agoMerge pull request #519 from dyninst/power_abi_v2_fixes
Xiaozhu Meng [Wed, 19 Dec 2018 19:33:34 +0000 (13:33 -0600)]
Merge pull request #519 from dyninst/power_abi_v2_fixes

Power abi v2 fixes

19 months agoFix code gen for PLT call/jump in dynamic instrumentation on Power 519/head
Xiaozhu Meng [Wed, 19 Dec 2018 17:15:28 +0000 (11:15 -0600)]
Fix code gen for PLT call/jump in dynamic instrumentation on Power

19 months agoThe red zone in Power ABI v2 contains 288 bytes for user code and
Xiaozhu Meng [Wed, 19 Dec 2018 15:43:30 +0000 (09:43 -0600)]
The red zone in Power ABI v2 contains 288 bytes for user code and
224 more bytes for system code. To be safe, we move down stack pointer
512 bytes to avoid overwriting any useful data.

19 months agoSeveral bug fixes on binary rewriting on Power
Xiaozhu Meng [Wed, 19 Dec 2018 15:02:26 +0000 (09:02 -0600)]
Several bug fixes on binary rewriting on Power

1. Fix TOC address calculation
2. Fix PLT call/jump
3. Adjust GLINK entry in .dynamic section, which points to the PLT resolver
4. Adjust R_PPC64_RELATIVE relocation entries

19 months agoFix modifyData to correctly emit instructions
Sasha @leela [Fri, 14 Dec 2018 01:38:22 +0000 (19:38 -0600)]
Fix modifyData to correctly emit instructions
when the offset of LDR (literal) instructions, after a relocation,
is larger than +-1MB.
test_reloc passes.

19 months agoEnable detach from process and leave stopped
Benjamin Welton [Fri, 7 Dec 2018 23:13:57 +0000 (17:13 -0600)]
Enable detach from process and leave stopped

Enables the ability to detach from a process but leave it in a stopped state

(cherry picked from commit 8470129b60a6c13b21839234f9804c355a73d8a4)

19 months agoDon't use system header <> syntax for dyninst includes 518/head
Stan Cox [Mon, 10 Dec 2018 22:48:46 +0000 (17:48 -0500)]
Don't use system header <> syntax for dyninst includes

20 months agoalways compute line info for CUBINs using parseLineInfoForObject 516/head
John Mellor-Crummey [Fri, 7 Dec 2018 21:59:47 +0000 (15:59 -0600)]
always compute line info for CUBINs using parseLineInfoForObject

20 months agoMerge branch 'master' of https://github.com/dyninst/dyninst
John Mellor-Crummey [Sat, 8 Dec 2018 04:46:29 +0000 (22:46 -0600)]
Merge branch 'master' of https://github.com/dyninst/dyninst

20 months agoMerge pull request #510 from dyninst/fix/whileExpr
Xiaozhu Meng [Fri, 7 Dec 2018 23:18:19 +0000 (17:18 -0600)]
Merge pull request #510 from dyninst/fix/whileExpr

Fix whileExpr not generating the correct code and causing abort

20 months agoMerge pull request #513 from jmellorcrummey/fix-openmp-link
Xiaozhu Meng [Fri, 7 Dec 2018 16:42:48 +0000 (10:42 -0600)]
Merge pull request #513 from jmellorcrummey/fix-openmp-link

as needed, add -fopenmp flag when linking executables

20 months agoMerge pull request #507 from stanfordcox/scox/examples
Xiaozhu Meng [Fri, 7 Dec 2018 16:38:19 +0000 (10:38 -0600)]
Merge pull request #507 from stanfordcox/scox/examples

Add .dir suffix to examples/{codeCoverage,unstrip}

20 months agoMerge pull request #506 from stanfordcox/scox/doc
Xiaozhu Meng [Fri, 7 Dec 2018 16:32:29 +0000 (10:32 -0600)]
Merge pull request #506 from stanfordcox/scox/doc

Install docs into target doc dirs

20 months agoMerge pull request #509 from dyninst/fix_sign_unsigned
Xiaozhu Meng [Fri, 7 Dec 2018 16:26:00 +0000 (10:26 -0600)]
Merge pull request #509 from dyninst/fix_sign_unsigned

Fixes signed/unsigned operations for comparison, multiplication,

20 months agoThe right shift implementation on power is wrong. Do not use it for division. 509/head
Xiaozhu Meng [Fri, 7 Dec 2018 16:20:27 +0000 (10:20 -0600)]
The right shift implementation on power is wrong. Do not use it for division.

20 months agoFix 64-bit sign/unsigned comparison, multi, and division on ARM
Xiaozhu Meng [Fri, 7 Dec 2018 15:13:45 +0000 (09:13 -0600)]
Fix 64-bit sign/unsigned comparison, multi, and division on ARM

20 months agoas needed, add -fopenmp flag when linking executables 513/head
John Mellor-Crummey [Fri, 7 Dec 2018 04:24:20 +0000 (22:24 -0600)]
as needed, add -fopenmp flag when linking executables

20 months agoFix 64-bit sign/unsigned comparison, multi, and division on power
Xiaozhu Meng [Thu, 6 Dec 2018 20:03:49 +0000 (14:03 -0600)]
Fix 64-bit sign/unsigned comparison, multi, and division on power

20 months agoast: fix whileOp 510/head
LER0ever [Thu, 6 Dec 2018 05:56:49 +0000 (23:56 -0600)]
ast: fix whileOp

the current whileOp code is mostly from ifOp since they share mostly the
same high level logic.
We should update whileOp code whenever we make a future change to ifOp

20 months agocmake: export CompilerCommands for IDE jump-to-def support
LER0ever [Thu, 6 Dec 2018 05:56:22 +0000 (23:56 -0600)]
cmake: export CompilerCommands for IDE jump-to-def support

20 months agoImplements getDynamicCallSiteArgs to monitor dynamic call sites.
Sasha @leela [Thu, 6 Dec 2018 00:14:08 +0000 (18:14 -0600)]
Implements getDynamicCallSiteArgs to monitor dynamic call sites.
Implements emitLoadOrigRegister to get frame pointer register.
Test1_40 passes.

20 months agoStart to fix signed/unsigned operations for comparison, multiplication,
Xiaozhu Meng [Wed, 5 Dec 2018 22:07:42 +0000 (16:07 -0600)]
Start to fix signed/unsigned operations for comparison, multiplication,
and division.

This commit contains platform independent changes and platform dependent
changes for x86-64

20 months agoEmit 64-bit integer multiplication and division on power
Xiaozhu Meng [Mon, 3 Dec 2018 17:21:10 +0000 (11:21 -0600)]
Emit 64-bit integer multiplication and division on power

20 months agoAdd .dir suffix to examples/{codeCoverage,unstrip} 507/head
Stan Cox [Fri, 30 Nov 2018 17:20:14 +0000 (12:20 -0500)]
Add .dir suffix to examples/{codeCoverage,unstrip}

20 months agoUpdate the stack locations to find for parameters, as there is an ABI change since...
Xiaozhu Meng [Fri, 30 Nov 2018 17:05:19 +0000 (11:05 -0600)]
Update the stack locations to find for parameters, as there is an ABI change since power 8

20 months agoInstall docs into target doc dirs 506/head
Stan Cox [Fri, 30 Nov 2018 03:08:29 +0000 (22:08 -0500)]
Install docs into target doc dirs

20 months agoMerge branch 'master' into ARMv8
Sasha @leela [Wed, 28 Nov 2018 23:26:46 +0000 (17:26 -0600)]
Merge branch 'master' into ARMv8

20 months agoFix wrong handling for PTRACE_EVENT_EXIT in proccontrol. Currently, each time we...
Xiaozhu Meng [Wed, 28 Nov 2018 21:56:15 +0000 (15:56 -0600)]
Fix wrong handling for PTRACE_EVENT_EXIT in proccontrol. Currently, each time we see PTRACE_EVENT_EXIT, we assume the mutatee exited normally. However, this is a wrong assumption. Based on the man page of PTRACE:

PTRACE_EVENT_EXIT will happen before actual death,  This applies to exits via
exit(2), exit_group(2), and signal deaths

PTRACE_EVENT_EXIT will also be delivered to proccontrol when the mutatee
died of crashes/signals. So, we need to check whether the waitpid status
represents a normal exit or a signal exit

20 months agoFix long branch generation.
Sasha @leela [Wed, 21 Nov 2018 19:40:47 +0000 (13:40 -0600)]
Fix long branch generation.
Fix emit load register indirect.
Implements hasBeenBound for ARM.
Tests passing now: test1_14, 24, 26, 27, 28, 29, and 39.

20 months agoUpdate README.md
Xiaozhu Meng [Mon, 19 Nov 2018 17:02:42 +0000 (11:02 -0600)]
Update README.md

20 months agoImplementing emitLoadOrigRegRelative and emitStoreIndir.
Sasha @leela [Sat, 17 Nov 2018 01:21:32 +0000 (19:21 -0600)]
Implementing emitLoadOrigRegRelative and emitStoreIndir.
Adding case of loadRegRelativeOp and storeIndirOp for emitVload.
test1_23 passes.

20 months agoMerge branch 'master' of https://github.com/dyninst/dyninst
Sasha Nicolas [Fri, 9 Nov 2018 17:41:29 +0000 (11:41 -0600)]
Merge branch 'master' of https://github.com/dyninst/dyninst

20 months agoMerge branch 'master' into ARMv8
Sasha @leela [Fri, 9 Nov 2018 17:01:06 +0000 (11:01 -0600)]
Merge branch 'master' into ARMv8

20 months agoUpdate latex based manuals v10.0.0
Xiaozhu Meng [Fri, 9 Nov 2018 16:48:08 +0000 (10:48 -0600)]
Update latex based manuals

20 months agoMerge branch 'master' into ARMv8
Sasha @leela [Fri, 9 Nov 2018 16:28:31 +0000 (10:28 -0600)]
Merge branch 'master' into ARMv8

20 months agoMore updates to README and docx based manuals
Xiaozhu Meng [Fri, 9 Nov 2018 16:17:46 +0000 (10:17 -0600)]
More updates to README and docx based manuals

21 months agoFix generateLongBranch to make Replace Function work.
Sasha @leela [Fri, 9 Nov 2018 00:50:47 +0000 (18:50 -0600)]
Fix generateLongBranch to make Replace Function work.
test1_22 passes.

21 months agoClear debugging output
Xiaozhu Meng [Thu, 8 Nov 2018 21:57:08 +0000 (15:57 -0600)]
Clear debugging output

21 months agoUpdate README.md
Sasha NĂ­colas [Thu, 8 Nov 2018 21:40:02 +0000 (15:40 -0600)]
Update README.md

21 months agoCorrect LDR/STR instructions for SIMD&FP
Sasha @leela [Thu, 8 Nov 2018 21:22:27 +0000 (15:22 -0600)]
Correct LDR/STR instructions for SIMD&FP
Saving all FP registers in BaseTramp
Remove #if for DYNINST_snippetBreakpoint