[DynInst_API:] [dyninst/dyninst] 205939: Add CMake stub


Date: Wed, 27 Dec 2023 12:53:48 -0800
From: Tim Haines <noreply@xxxxxxxxxx>
Subject: [DynInst_API:] [dyninst/dyninst] 205939: Add CMake stub
  Branch: refs/heads/thaines/capstone_integration
  Home:   https://github.com/dyninst/dyninst
  Commit: 205939222d5d3f9233c80111fb91c6312a81a9c8
      https://github.com/dyninst/dyninst/commit/205939222d5d3f9233c80111fb91c6312a81a9c8
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M CMakeLists.txt
    A cmake/tpls/DyninstCapstone.cmake
    M instructionAPI/CMakeLists.txt

  Log Message:
  -----------
  Add CMake stub


  Commit: e25173d2f86640725f3401999ed6924860ef5ab6
      https://github.com/dyninst/dyninst/commit/e25173d2f86640725f3401999ed6924860ef5ab6
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/capstone/import.py
    M instructionAPI/capstone/x86.py

  Log Message:
  -----------
  Make parameter the root directory in import script

Instead of specifying the file name, the user just points to the
directory and the script will grab the necessary files.


  Commit: af4fc00f3a879bf0fc9511d4901fe26d9e136ee9
      https://github.com/dyninst/dyninst/commit/af4fc00f3a879bf0fc9511d4901fe26d9e136ee9
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/capstone/import.py
    M instructionAPI/capstone/x86.py

  Log Message:
  -----------
  Alias faddp to fadd

Capstone only uses fadd. This does not modify the entryIDs yet.


  Commit: 16efbbe0eeb17aea0de2f11c0a3340d857ce0de8
      https://github.com/dyninst/dyninst/commit/16efbbe0eeb17aea0de2f11c0a3340d857ce0de8
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/capstone/import.py

  Log Message:
  -----------
  Add mnemonic translation to import script


  Commit: 38d4a6fa8ef4cf98ebcfd8600fd78ebb219c8d3e
      https://github.com/dyninst/dyninst/commit/38d4a6fa8ef4cf98ebcfd8600fd78ebb219c8d3e
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    A instructionAPI/src/x86/register-xlat.C
    A instructionAPI/src/x86/register-xlat.h

  Log Message:
  -----------
  Add Capstone->Dyninst register translation


  Commit: 452397c711eeed7e2b220e5c66127fe5f16900ff
      https://github.com/dyninst/dyninst/commit/452397c711eeed7e2b220e5c66127fe5f16900ff
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    A instructionAPI/src/x86/mnemonic-xlat.C
    A instructionAPI/src/x86/mnemonic-xlat.h

  Log Message:
  -----------
  Add Capstone->Dyninst mnemonic translation


  Commit: 07f2793ff68e38ac21f06e63171eeb3414b07cb4
      https://github.com/dyninst/dyninst/commit/07f2793ff68e38ac21f06e63171eeb3414b07cb4
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/InstructionDecoder-x86.C

  Log Message:
  -----------
  InstructionDecoder-x86.C whitespace


  Commit: 84f5fbbfe82ad7095398a1df4d4f29c7bbc73fc6
      https://github.com/dyninst/dyninst/commit/84f5fbbfe82ad7095398a1df4d4f29c7bbc73fc6
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/CMakeLists.txt
    M instructionAPI/h/Instruction.h
    M instructionAPI/src/InstructionDecoderImpl.C
    A instructionAPI/src/x86/decoder.C
    A instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  Add stub replacement for x86 decoder


  Commit: c52be906260763acd644c6e5cb9c372001d5ac6e
      https://github.com/dyninst/dyninst/commit/c52be906260763acd644c6e5cb9c372001d5ac6e
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C
    M instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  Add decoder ctor and dtor

There is one usage of Capstone per decoder. This should be threadsafe
as it doesn't make sense to use a decoder with multiple threads
simultaneously. See comments in ctor for why there are two Capstone
handles per decoder.


  Commit: fc85b11c6f20b7f71d577a98a62a2b4b10db63a1
      https://github.com/dyninst/dyninst/commit/fc85b11c6f20b7f71d577a98a62a2b4b10db63a1
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add decodeOpcode


  Commit: 89a752da67cf7e7c50f8bd0547197bb0105795fb
      https://github.com/dyninst/dyninst/commit/89a752da67cf7e7c50f8bd0547197bb0105795fb
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add note in decodeOperands


  Commit: 76c264bc1e2f85d696b6fac1af03cba33423a88e
      https://github.com/dyninst/dyninst/commit/76c264bc1e2f85d696b6fac1af03cba33423a88e
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C
    M instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  Add doDelayedDecode

This is a copy/paste of Xiaozhu's implementation. It appears to be
incomplete (as per the comments).


  Commit: 0a4393be79a79703714e019888f05734c2262947
      https://github.com/dyninst/dyninst/commit/0a4393be79a79703714e019888f05734c2262947
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  stub -- refactor


  Commit: cc0e435e1e61342e1208a3c544fdbc893a3d723f
      https://github.com/dyninst/dyninst/commit/cc0e435e1e61342e1208a3c544fdbc893a3d723f
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C
    M instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  Use disassembler object in decode_operands


  Commit: 2a881293982c3cdbfa42326632d924b424dcef40
      https://github.com/dyninst/dyninst/commit/2a881293982c3cdbfa42326632d924b424dcef40
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C
    M instructionAPI/src/x86/decoder.h

  Log Message:
  -----------
  Refactor decode_operands

This makes it much easier to follow.


  Commit: 8bc975736ce2fb0e40c70b0dc9b7812f514b57cf
      https://github.com/dyninst/dyninst/commit/8bc975736ce2fb0e40c70b0dc9b7812f514b57cf
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add detailed comments about operand types


  Commit: 0aa5244e44b8d51cba5127298cb108e9ec64b2f7
      https://github.com/dyninst/dyninst/commit/0aa5244e44b8d51cba5127298cb108e9ec64b2f7
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Use Instruction::makeReturnExpression

No need to reinvent the wheel.


  Commit: 67ff3ca59fedf47214395a9ebc64eaf7ed645b39
      https://github.com/dyninst/dyninst/commit/67ff3ca59fedf47214395a9ebc64eaf7ed645b39
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Remove redundant includes


  Commit: 4ab5be5a87a21505e32fb0c435526e916b8b2bba
      https://github.com/dyninst/dyninst/commit/4ab5be5a87a21505e32fb0c435526e916b8b2bba
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Refactor handling of implicit registers

By giving the properties names rather than std::pairs, it makes it much
easier to read.


  Commit: 1cc41bcbdf93ae0718fa2a3d92a3708b2ce5377f
      https://github.com/dyninst/dyninst/commit/1cc41bcbdf93ae0718fa2a3d92a3708b2ce5377f
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Include decoding of {e,r}flags


  Commit: 055a54acc839e4597f7276822e60ff29f8b625bd
      https://github.com/dyninst/dyninst/commit/055a54acc839e4597f7276822e60ff29f8b625bd
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Fix comment for explicit operands


  Commit: e4ddf9086b191f8f45f34f33918147f245852698
      https://github.com/dyninst/dyninst/commit/e4ddf9086b191f8f45f34f33918147f245852698
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Fix explicit operands example


  Commit: cfca6ee1a159b08d661b5227550d741256bffd6d
      https://github.com/dyninst/dyninst/commit/cfca6ee1a159b08d661b5227550d741256bffd6d
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Remove extraneous namespace qualifier


  Commit: 193941e0e973b808b9b7331bed1088b0ed38cdd9
      https://github.com/dyninst/dyninst/commit/193941e0e973b808b9b7331bed1088b0ed38cdd9
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Refactor is_call

The original code did the nested check, but didn't need to.

  if(cat == c_BranchInsn || cat == c_CallInsn) {
    isCFT = true;
    if(cat == c_CallInsn) {
      isCall = true;
    }
  }

is equivalent to

  if(cat == c_CallInsn) {
    isCall = true;
  }

  if(cat == c_BranchInsn || isCall) {
    isCFT = true;
  }


  Commit: 228c85289a837908811732f512e90bcb0ec6dd67
      https://github.com/dyninst/dyninst/commit/228c85289a837908811732f512e90bcb0ec6dd67
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Fix comment in expand_eflags


  Commit: 32aa6f354e5b3bdccfb32d30d3bfa9dded5be5e6
      https://github.com/dyninst/dyninst/commit/32aa6f354e5b3bdccfb32d30d3bfa9dded5be5e6
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/register-xlat.C

  Log Message:
  -----------
  Fix comment for BND registers


  Commit: 5b1735e081814f198b2d9d361dfabd321c0f9463
      https://github.com/dyninst/dyninst/commit/5b1735e081814f198b2d9d361dfabd321c0f9463
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Refactor isCFT in decode_reg


  Commit: badeb11adc2bf950ec9bd50f72a9442f1f244a90
      https://github.com/dyninst/dyninst/commit/badeb11adc2bf950ec9bd50f72a9442f1f244a90
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Refactor isCFT in decode_imm


  Commit: 5f810eeb6e918619b367fdbf6822ce4fc800dec7
      https://github.com/dyninst/dyninst/commit/5f810eeb6e918619b367fdbf6822ce4fc800dec7
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Use signed 64-bit values for immediates


  Commit: 19a0f7e6729339da19dcea49bce8f00d58779cf8
      https://github.com/dyninst/dyninst/commit/19a0f7e6729339da19dcea49bce8f00d58779cf8
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Update comment for relative branch immediates


  Commit: ff6f81452894a3022859bc2e26914468363232ca
      https://github.com/dyninst/dyninst/commit/ff6f81452894a3022859bc2e26914468363232ca
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Remove error check on size_to_type

It has been updated to include all values used by Capstone.


  Commit: 1ef9bf205fb1c290d11d6be20a91acc0c7980314
      https://github.com/dyninst/dyninst/commit/1ef9bf205fb1c290d11d6be20a91acc0c7980314
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Remove unneeded assert


  Commit: 9da139e22c539561ef08c954eb7d9e9ca1a986c0
      https://github.com/dyninst/dyninst/commit/9da139e22c539561ef08c954eb7d9e9ca1a986c0
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Move is_call and is_cft to where they are used


  Commit: fea5fcb26eef0e057ee9b0e4fe147bf860f958ee
      https://github.com/dyninst/dyninst/commit/fea5fcb26eef0e057ee9b0e4fe147bf860f958ee
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Use signed values for calculations

The manual says everything but the scale can be positive or negative.


  Commit: 08a6b17adc991d3721e46b47130c48c6ebd6f6e3
      https://github.com/dyninst/dyninst/commit/08a6b17adc991d3721e46b47130c48c6ebd6f6e3
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Use braces


  Commit: ffd750ad71ea7d37777dae4463cfd84ebc81b060
      https://github.com/dyninst/dyninst/commit/ffd750ad71ea7d37777dae4463cfd84ebc81b060
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Move size_to_type to where it is used


  Commit: 6502c0906b20d27984b0d0032e07f114c95a745f
      https://github.com/dyninst/dyninst/commit/6502c0906b20d27984b0d0032e07f114c95a745f
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add some whitespace


  Commit: 2bef2bac3aa39ea2592b8a4870cf759f68b9c87d
      https://github.com/dyninst/dyninst/commit/2bef2bac3aa39ea2592b8a4870cf759f68b9c87d
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add description from Intel manual


  Commit: c2c69067bc9064f0ed0e40377887afb1d182748b
      https://github.com/dyninst/dyninst/commit/c2c69067bc9064f0ed0e40377887afb1d182748b
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Return early if processing a CFT


  Commit: 36be2c3e67c4f3614011e9aea97c73a28ac147fd
      https://github.com/dyninst/dyninst/commit/36be2c3e67c4f3614011e9aea97c73a28ac147fd
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Add comment about LEA


  Commit: fbf16e3d5d9d89b46e2c4002dff48ec546a1c5e9
      https://github.com/dyninst/dyninst/commit/fbf16e3d5d9d89b46e2c4002dff48ec546a1c5e9
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Rename immAST -> displacementAST

This better reflects its meaning.


  Commit: 429887e6b4ffa7e7056ae747d939b9108523fbf7
      https://github.com/dyninst/dyninst/commit/429887e6b4ffa7e7056ae747d939b9108523fbf7
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Handle segment registers as memory operands


  Commit: a8223c85366cc4433c84ea2cf2faaacd36c8c1e0
      https://github.com/dyninst/dyninst/commit/a8223c85366cc4433c84ea2cf2faaacd36c8c1e0
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/CMakeLists.txt

  Log Message:
  -----------
  Fix cmake formatting in instructionAPI/CMakeLists.txt


  Commit: 01579fc7099b1d2756a8d55081ed7c546fc8aefa
      https://github.com/dyninst/dyninst/commit/01579fc7099b1d2756a8d55081ed7c546fc8aefa
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M .github/workflows/dependency-version.yaml
    M docker/dependencies.versions

  Log Message:
  -----------
  Add dependency-version check for Capstone


  Commit: a17248a8045ef88d88e6e166293422b316c57500
      https://github.com/dyninst/dyninst/commit/a17248a8045ef88d88e6e166293422b316c57500
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/CMakeLists.txt

  Log Message:
  -----------
  Make Capstone a private dependency


  Commit: 43aa6d86b10cc767a38d280b200c71edf256d1d4
      https://github.com/dyninst/dyninst/commit/43aa6d86b10cc767a38d280b200c71edf256d1d4
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M docker/Dockerfile.fedora
    M docker/Dockerfile.ubuntu
    A docker/build_capstone.sh
    M docker/dependencies.versions

  Log Message:
  -----------
  Docker: add Capstone builds


  Commit: b1d9c092392afe989d441873e99c760a45268d6c
      https://github.com/dyninst/dyninst/commit/b1d9c092392afe989d441873e99c760a45268d6c
  Author: Tim Haines <thaines.astro@xxxxxxxxx>
  Date:   2023-12-27 (Wed, 27 Dec 2023)

  Changed paths:
    M instructionAPI/src/x86/decoder.C

  Log Message:
  -----------
  Only decode segment register operands for i386


Compare: https://github.com/dyninst/dyninst/compare/c1e01b186cc8...b1d9c092392a
[← Prev in Thread] Current Thread [Next in Thread→]
  • [DynInst_API:] [dyninst/dyninst] 205939: Add CMake stub, Tim Haines <=