Page MenuHomePhabricator

0x59616e (Sheng)
User

Projects

User does not belong to any projects.

User Details

User Since
Nov 15 2021, 11:20 PM (26 w, 2 d)

Recent Activity

Today

0x59616e committed rGdf25f0d5202b: [M68k] Fix a bug in disassembler (authored by 0x59616e).
[M68k] Fix a bug in disassembler
Thu, May 19, 6:20 AM · Restricted Project, Restricted Project
0x59616e committed rG017c98276b07: [NFC][M68k] Replace `APInt::zextOrSelf` with `APInt::zext` (authored by 0x59616e).
[NFC][M68k] Replace `APInt::zextOrSelf` with `APInt::zext`
Thu, May 19, 5:47 AM · Restricted Project, Restricted Project

Yesterday

0x59616e updated the diff for D125948: [M68k] Fix decoding conflict between move instructions and their tail call version.

Fix failed test

Wed, May 18, 11:31 PM · Restricted Project, Restricted Project
0x59616e planned changes to D125948: [M68k] Fix decoding conflict between move instructions and their tail call version.

Didn't notice some test were failed.

Wed, May 18, 11:27 PM · Restricted Project, Restricted Project
0x59616e retitled D125948: [M68k] Fix decoding conflict between move instructions and their tail call version from Fix decoding conflict between move instructions and their tail call version to [M68k] Fix decoding conflict between move instructions and their tail call version.
Wed, May 18, 11:25 PM · Restricted Project, Restricted Project
0x59616e requested review of D125948: [M68k] Fix decoding conflict between move instructions and their tail call version.
Wed, May 18, 11:22 PM · Restricted Project, Restricted Project
0x59616e committed rGa5d618b393fe: [M68k][Disassembler] Fix decoding conflict (authored by 0x59616e).
[M68k][Disassembler] Fix decoding conflict
Wed, May 18, 6:11 PM · Restricted Project, Restricted Project
0x59616e closed D125861: [M68k][Disassembler] Fix decoding conflict.
Wed, May 18, 6:11 PM · Restricted Project, Restricted Project
0x59616e added a comment to D125861: [M68k][Disassembler] Fix decoding conflict.

Thanks !

Wed, May 18, 6:07 PM · Restricted Project, Restricted Project
0x59616e added inline comments to D125861: [M68k][Disassembler] Fix decoding conflict.
Wed, May 18, 3:12 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D125861: [M68k][Disassembler] Fix decoding conflict.

Add comment

Wed, May 18, 2:38 AM · Restricted Project, Restricted Project
0x59616e requested review of D125861: [M68k][Disassembler] Fix decoding conflict.
Wed, May 18, 1:44 AM · Restricted Project, Restricted Project

Mon, May 16

0x59616e committed rGaab5bd180a42: [ADT] Adopt the new casting infrastructure for PointerUnion (authored by 0x59616e).
[ADT] Adopt the new casting infrastructure for PointerUnion
Mon, May 16, 3:40 AM · Restricted Project, Restricted Project
0x59616e closed D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.
Mon, May 16, 3:40 AM · Restricted Project, Restricted Project

Sun, May 15

0x59616e added a comment to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Thanks @lattner @bzcheeseman ! I'll land this patch after making sure everything runs smoothly.

Sun, May 15, 11:33 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

fix typo

Sun, May 15, 11:32 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120960: [M68k][Disassembler] Adopt the new variable length decoder.

That's expected. I'll open an issue for it later this day.

Sun, May 15, 6:57 PM · Restricted Project, Restricted Project
0x59616e added a comment to D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.

@myhsu this file has dependency on MCFixedLenDisassembler.h, but I'm not quite sure whether we should take care of it, given that I did not encounter any failure during building and testing. What's your opinion ?

Sun, May 15, 5:33 AM · Restricted Project, Restricted Project
0x59616e added a comment to D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.
Sun, May 15, 5:25 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

apply clang-format

Sun, May 15, 4:52 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

update diff trying to fix buildbot failure

Sun, May 15, 2:03 AM · Restricted Project, Restricted Project

Sat, May 14

0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

update diff

  • define our own castFailed in the hope of fixing the build failure of clang.
  • add static_assert for type check
Sat, May 14, 11:03 PM · Restricted Project, Restricted Project
0x59616e added a comment to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

It seems that people are not always using a plain pointer in PointerUnion. Sometimes they seem to use a custom smart pointer ?

Sat, May 14, 10:44 PM · Restricted Project, Restricted Project
0x59616e added inline comments to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.
Sat, May 14, 10:43 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.
  • public inheritance for ConstStrippingForwardingCast
Sat, May 14, 9:51 PM · Restricted Project, Restricted Project
0x59616e added inline comments to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.
Sat, May 14, 9:50 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Address feedback

  • Add test case for const
  • Add some comments.
Sat, May 14, 9:49 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

I used arc incorrectly. Re-update the diff.

Sat, May 14, 9:16 PM · Restricted Project, Restricted Project
0x59616e added a comment to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Thanks for feedback ;)

Sat, May 14, 9:12 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Implement CastInfoPointerUnionImpl

Sat, May 14, 9:11 PM · Restricted Project, Restricted Project
0x59616e added a comment to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

I can only come up with this :

Sat, May 14, 8:22 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Didn't notice the build failure. Remove the CastInfoPointerUnionImpl and revert
back to the original implementation.

Sat, May 14, 7:52 PM · Restricted Project, Restricted Project
0x59616e added a comment to D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Given that I'm still young to C++ and llvm, every suggestion, even the
one you feel it's trivial, are very welcomed ;)

This diff comes with the following updates:

  • Define PointerUnion::is and ::get in terms of isa<T> and cast<T>.
  • Add FIXME comment for is(), get() and dyn_cast().
Sat, May 14, 7:28 PM · Restricted Project, Restricted Project
0x59616e added reviewers for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion: bzcheeseman, lattner, rriddle, myhsu.
Sat, May 14, 7:25 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.

Given that I'm still young to C++ and llvm, every suggestion, even the
one you feel it's trivial, are very welcomed ;)

Sat, May 14, 7:25 PM · Restricted Project, Restricted Project
0x59616e committed rGc644488a8b8a: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h` (authored by 0x59616e).
Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`
Sat, May 14, 5:45 PM · Restricted Project, Restricted Project
0x59616e committed rGcf0b6df6dbf5: [M68k][Disassembler] Adopt the new variable length decoder (authored by 0x59616e).
[M68k][Disassembler] Adopt the new variable length decoder
Sat, May 14, 5:45 PM · Restricted Project, Restricted Project
0x59616e closed D120960: [M68k][Disassembler] Adopt the new variable length decoder.
Sat, May 14, 5:45 PM · Restricted Project, Restricted Project
0x59616e closed D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.
Sat, May 14, 5:45 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120960: [M68k][Disassembler] Adopt the new variable length decoder.

Thanks ! Appreciate your help ;)

Sat, May 14, 5:40 PM · Restricted Project, Restricted Project
0x59616e retitled D125609: [ADT] Adopt the new casting infrastructure for PointerUnion from Adopt the new casting infrastructure for PointerUnion to [ADT] Adopt the new casting infrastructure for PointerUnion.
Sat, May 14, 9:03 AM · Restricted Project, Restricted Project
0x59616e requested review of D125609: [ADT] Adopt the new casting infrastructure for PointerUnion.
Sat, May 14, 9:03 AM · Restricted Project, Restricted Project

Wed, May 11

0x59616e added a reviewer for D125444: [M68k] Add MC support for link/unlk: myhsu.
Wed, May 11, 8:12 PM · Restricted Project, Restricted Project
0x59616e requested review of D125444: [M68k] Add MC support for link/unlk.
Wed, May 11, 8:11 PM · Restricted Project, Restricted Project

Mon, May 9

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

The comment is updated :
1284ce917b5a

Mon, May 9, 7:33 PM · Restricted Project, Restricted Project
0x59616e committed rG1284ce917b5a: [NFC] Modify the comment to reflect the changes in decoder (authored by 0x59616e).
[NFC] Modify the comment to reflect the changes in decoder
Mon, May 9, 7:32 PM · Restricted Project, Restricted Project

Thu, May 5

0x59616e updated the diff for D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.

fix the include guard

Thu, May 5, 5:17 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

I've commited a diff in the hope of fixing this problem:

Thu, May 5, 5:11 PM · Restricted Project, Restricted Project
0x59616e committed rG9c2121b843ff: [NFC][test] Replace hardcoded number with numeric substitution blocks (authored by 0x59616e).
[NFC][test] Replace hardcoded number with numeric substitution blocks
Thu, May 5, 5:09 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.

change the header guard

Thu, May 5, 12:13 AM · Restricted Project, Restricted Project
0x59616e added a reviewer for D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`: myhsu.
Thu, May 5, 12:01 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

rebase

Thu, May 5, 12:00 AM · Restricted Project, Restricted Project

Wed, May 4

0x59616e updated the summary of D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.
Wed, May 4, 11:59 PM · Restricted Project, Restricted Project
0x59616e retitled D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h` from Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h` The name `MCFixedLenDisassembler.h` is out of date after D120958. Rename it as `MCDecoderOps.h` to reflect the change. to Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.
Wed, May 4, 11:58 PM · Restricted Project, Restricted Project
0x59616e requested review of D124987: Rename `MCFixedLenDisassembler.h` as `MCDecoderOps.h`.
Wed, May 4, 11:58 PM · Restricted Project, Restricted Project

Tue, May 3

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

For the record, to get this to build with my downstream target, I had to add:

MyInsnType MyInsnType::operator&(const uint64_t &RHS);
bool MyInsnType::operator!=(const int &RHS);

Thanks for your information. I'll update the comment.

Tue, May 3, 8:00 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120960: [M68k][Disassembler] Adopt the new variable length decoder.

just want to double check: all of the previously-XFAIL tests are now passing, right?

Yes. I don't see any 'unexpectedly passed' test.

This is a good news and proofs that the new variable-length decoder infrastructure works at scale :-)
(at least at a certain scale given that we still more coverage on our disassembler tests)

Tue, May 3, 7:49 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

For the record, to get this to build with my downstream target, I had to add:

MyInsnType MyInsnType::operator&(const uint64_t &RHS);
bool MyInsnType::operator!=(const int &RHS);
Tue, May 3, 7:47 PM · Restricted Project, Restricted Project

Mon, May 2

0x59616e committed rGdf3765bfdc13: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter` (authored by 0x59616e).
[NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`
Mon, May 2, 12:38 PM · Restricted Project, Restricted Project
0x59616e committed rG28e850a8da51: [TableGen] Add support for variable length instruction in decoder generator (authored by 0x59616e).
[TableGen] Add support for variable length instruction in decoder generator
Mon, May 2, 12:38 PM · Restricted Project, Restricted Project
0x59616e added a reverting change for rGba59ec2843f9: Fix a misuse of `cast`: rG522d90528e5a: Revert "Fix a misuse of `cast`".
Mon, May 2, 12:38 PM · Restricted Project, Restricted Project
0x59616e committed rG522d90528e5a: Revert "Fix a misuse of `cast`" (authored by 0x59616e).
Revert "Fix a misuse of `cast`"
Mon, May 2, 12:38 PM · Restricted Project, Restricted Project
0x59616e closed D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.
Mon, May 2, 12:37 PM · Restricted Project, Restricted Project
0x59616e closed D120958: [TableGen] Add support for variable length instruction in decoder generator.
Mon, May 2, 12:37 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

lgtm. Thanks for the patch!

Mon, May 2, 12:18 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120960: [M68k][Disassembler] Adopt the new variable length decoder.

just want to double check: all of the previously-XFAIL tests are now passing, right?

Mon, May 2, 12:14 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

address feedback:

  • use llvm::alignTo
  • construct APInt directly with constructor instead of assignment copy constructor
Mon, May 2, 12:14 PM · Restricted Project, Restricted Project

Mon, Apr 25

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

ping. Any more suggestions ?

Mon, Apr 25, 6:10 PM · Restricted Project, Restricted Project

Apr 17 2022

0x59616e updated the diff for D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

continue addressing formating issues

Apr 17 2022, 2:42 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

Revert the TODO suggested my myhsu

Apr 17 2022, 2:08 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

address format issue

Apr 17 2022, 1:30 PM · Restricted Project, Restricted Project

Apr 10 2022

0x59616e committed rGba59ec2843f9: Fix a misuse of `cast` (authored by 0x59616e).
Fix a misuse of `cast`
Apr 10 2022, 6:23 PM · Restricted Project, Restricted Project

Apr 9 2022

0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

rebase

Apr 9 2022, 8:50 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

rebase

Apr 9 2022, 8:48 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

I could not remember whether I've modified this patch recently.

Apr 9 2022, 8:17 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

I know what is going on.

Apr 9 2022, 8:12 AM · Restricted Project, Restricted Project
0x59616e planned changes to D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

I've noticed the clang-format problem. The weird thing is, It happened after I rename this file, before I change anything in it. That makes me confusing. It should have not happened because I only change the file name.

Apr 9 2022, 7:46 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.

Rename the class name.

Apr 9 2022, 4:38 AM · Restricted Project, Restricted Project
0x59616e requested review of D123451: [NFC] Rename `FixedLenDecoderEmitter` as `DecoderEmitter`.
Apr 9 2022, 4:24 AM · Restricted Project, Restricted Project

Apr 5 2022

0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

rebase

Apr 5 2022, 4:16 PM · Restricted Project, Restricted Project

Apr 3 2022

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

Should we rename after this patch ? or before this patch ?

Apr 3 2022, 10:19 PM · Restricted Project, Restricted Project

Mar 31 2022

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

The logics look cleaner now.
Now a bigger question is: Should we still calling it FixedLenDecoderEmitter?

What about DecoderEmitter.cpp ?

Sounds good to me, but I would suggest you to send a RFC to the forum asking for consensus.
Especially to see if there is any comment from existing FixedLenDecoder users (e.g. AArch64 and ARM). Also, in the RFC, please briefly explain why you want to build this feature on top of FixedLenDecoder rather than writing a separate disassembler.

Mar 31 2022, 6:41 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

address feedback

Mar 31 2022, 6:37 PM · Restricted Project, Restricted Project

Mar 30 2022

0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

address feedback

Mar 30 2022, 5:30 AM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

The logics look cleaner now.
Now a bigger question is: Should we still calling it FixedLenDecoderEmitter?

Mar 30 2022, 5:27 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

move test into another file

Mar 30 2022, 5:25 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

address some feedbacks

Mar 30 2022, 5:02 AM · Restricted Project, Restricted Project

Mar 25 2022

0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

formatting

Mar 25 2022, 4:53 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

Remove tablegen variable isVarLenInst. It's useless

Mar 25 2022, 4:52 AM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

fix a minor problem

Mar 25 2022, 1:10 AM · Restricted Project, Restricted Project

Mar 24 2022

0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

rebase

Mar 24 2022, 3:41 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.
Mar 24 2022, 3:39 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D120958: [TableGen] Add support for variable length instruction in decoder generator.

address feedback

Mar 24 2022, 3:38 PM · Restricted Project, Restricted Project

Mar 21 2022

0x59616e committed rG23423c0ea8d4: [TableGen] Fix a misuse of getValueAsBitsInit (authored by 0x59616e).
[TableGen] Fix a misuse of getValueAsBitsInit
Mar 21 2022, 11:05 PM · Restricted Project

Mar 15 2022

0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

We can traverse the Segments of VarLenInst and use CGIOperandList::OperandInfo::ParseOperandName to get the operand number, and then add that Segments into the correspoding OpInfo according to the operand number.

For example, if we find "dst.reg" and use CGIOperandList::OperandInfo::ParseOperandName and know "Oh, this is the third operand", then we can add this into the third OpInfo.

In this way we can avoid overload BitsInit completely.

This approach sounds reasonable to me

Mar 15 2022, 6:52 PM · Restricted Project, Restricted Project
0x59616e added a comment to D120958: [TableGen] Add support for variable length instruction in decoder generator.

Thank you for the patch.
A high level question: It seems like generating a decoder requires two phases -- First, generates a list of OperandInfo, which is currently done by populateInstruction, then emit the real (C++) code according to these OperandInfo instances. My question is, can we use our own way -- possibly putting in a separate file -- to generate these OperandInfo before supplying them to the second phase, instead of trying to piggyback everything into the existing FixedLenDecoder framework?
Because, to be honest, I'm not a big fan of overloading the BitsInit (to carry operand info). Using a BitsInit might fit well for fixed-length instructions but I feel like there are more elegant ways to handle var-length instructions. For instance, using CGIOperandList::OperandInfo::ParseOperandName to parse suboperands rather than traversing every single in/out operands in the original instruction definition.

Mar 15 2022, 5:50 AM · Restricted Project, Restricted Project

Mar 10 2022

0x59616e updated the summary of D120958: [TableGen] Add support for variable length instruction in decoder generator.
Mar 10 2022, 3:38 PM · Restricted Project, Restricted Project

Mar 3 2022

0x59616e added reviewers for D120958: [TableGen] Add support for variable length instruction in decoder generator: myhsu, ricky26, RKSimon, craig.topper, resistor, jrtc27.
Mar 3 2022, 6:55 PM · Restricted Project, Restricted Project
0x59616e added reviewers for D120960: [M68k][Disassembler] Adopt the new variable length decoder: myhsu, ricky26, RKSimon.
Mar 3 2022, 6:48 PM · Restricted Project, Restricted Project
0x59616e updated the diff for D120960: [M68k][Disassembler] Adopt the new variable length decoder.

Fix a minor problem in the test

Mar 3 2022, 6:47 PM · Restricted Project, Restricted Project