일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
- linux debugging
- android inject
- thread local storage
- on stack replacement
- tracerpid
- Injection
- LLVM
- custom packer
- pinpoint
- pthread
- TLS
- LLVM Obfuscator
- 난독화
- on-stack replacement
- Linux packer
- so inject
- Linux custom packer
- v8 tracing
- initial-exec
- 안티디버깅
- tracing
- Android
- apm
- linux thread
- anti debugging
- LLVM 난독화
- OSR
- v8 optimizing
- uftrace
- Obfuscator
- Today
- Total
목록LLVM-STUDY (62)
Why should I know this?
https://die4taoam.tistory.com/122 LLVM 에 패치 보내기 튜토리얼 https://youtu.be/C5Y977rLqpw?si=JXvJ7RsQ-26XSW4i 패치 만들고 LLVM 에 보내기 코드를 수정한 뒤 LLVM 에 기여하는 방식은 code-review 과정을 별도의 플랫폼에서 거친다는 차이가 있습니다. 이에 대한 자세한 과정 die4taoam.tistory.com LLVM에 패치 보내는 튜터리얼은, Nikita Popov 가 작성한 글을 기반으로 작성됐습니다. 현재는 이 글에 포함되어 있는 리뷰과정은 모두 완전 github로 옮겨간 점 등이 달라졌으며, github 환경에 익숙한 사람들에게는 오히려 더 쉽게 LLVM에 기여할 수 있는 기회가 될 수 있을 것 같습니다. 이런저..
https://youtu.be/iV5jBtE35r4?si=DrrIq7UaO-bJSlZb 이걸 왜 못봤어나 싶다.
https://youtu.be/y4b-sgp6VYA?si=FBwXN-abkikLJwx0 cmake .. -GNinja \ -DCMAKE_BUILD_TYPE=Release \ -DLLVM_ENABLE_LLD=ON \ -DLLVM_ENABLE_PROJECTS="clang;lld;compiler-rt" \ -DLLVM_TARGETS_TO_BUILD="AArch64;ARM;X86" \ -DLLVM_ENABLE_ASSERTION=OFF -E : Stop before compiling -S : Stop before assembling -c : Stop before linking Dumping LEXER Tokens clang -Xclang -dump-tokens -E foo.cpp clang -Xclang -hel..
https://github.com/llvm/llvm-project/issues/33874 Improve bitfield arithmetic · Issue #33874 · llvm/llvm-project Bugzilla Link 34526 Version trunk OS Windows NT CC @alexey-bataev,@legrosbuffle,@rotateright Extended Description We could improve math ops on irregular bitfields with the relevant SWAR style patte... github.com 패치목적 // 기존에 생성되던 IR define dso_local i8 @AddCounters(Counters, Counters)(..
LLVM 에서 제공하는 비트 연산은 다음같은 연산을 추정하는데 한계가 있다. x == ~x x는 ~x와 같을 수 없다. false가 되야 한다. 이를 비트로 바꿔말하면, x에 가용한 비트 조합과 ~x의 가용한 비트 조합 간에 일치되는 조합이 없다고 할 수 있다. PossiblyBit Pb = PossiblyBit(X).matchPossiblyBit(PossiblyBit(~X)); ; Pb == nullptr 이에 연장으로 x s< ~x 는 어떨까? 이 연산은 x 의 Signbit 가 세팅되어 있는지 여부인지가 중요하다. 만약 x에 SignBit가 세팅되어 있다면, x s< ~x 는 true 이고, SignBit가 세팅되지 않았다면, x s< ~x 는 false 이다 signbit를 검사하는 것으로 단순화..
https://github.com/llvm/llvm-project/pull/74317 [InstCombine] Generalize folds for inversion of icmp operands by nikic · Pull Request #74317 · llvm/llvm-project We have a bunch of folds that basically perform X pred Y to ~Y pred ~X for various special cases where this saves an instruction. Generalize these folds to use isFreeToInvert(). We have to make sur... github.com // Transform (~X ^ Y) s< ..
~X NOT X A + B NOT -1 -B - A B - A NOT A + (-1 - B) A - B NOT B + (-1 - A) A ^ B NOT A ^ ~B A ^ ~B NOT A ^ B A s>> B NOT ~A s>>B 부연설명 A+B -> -1 -B -A (양->음전) 100+100 이라고 하면, 결과는 200, NOT은 -201이 나와야 함. -100 -100 -1 = -201 A-B -> B + (-A - 1(양>음전)) A^B -> A^~B ; A^B는 A를 -1로 생각하면 -1^B -> ~B가 됨. 이의 NOT은 B. -1^~B = B A s>> B -> ~A s>> B ; (몰?루?)
1. 정의 2. 주요 기능 3. 활용 예제 1. ConstantRange 는 ConstantRange.h 에 선언되어 있다. /// This class represents a range of values. 생성자 셋 ConstantRange::ConstantRange(uint32_t BitWidth, bool Full) : Lower(Full ? APInt::getMaxValue(BitWidth) : APInt::getMinValue(BitWidth)), Upper(Lower) {} ConstantRange::ConstantRange(APInt V) : Lower(std::move(V)), Upper(Lower + 1) {} ConstantRange::ConstantRange(APInt L, APInt ..
1. 기능 설명 2. 내부 함수 설명 3. 활용 설명 https://github.com/ParkHanbum/llvm-project/commit/d77067d08a3f56dc2d0e6c95bd2852c943df743a [ValueTracking] Add dominating condition support in computeKnownBits(… · ParkHanbum/llvm-project@d77067d …) (#73662) This adds support for using dominating conditions in computeKnownBits() when called from InstCombine. The implementation uses a DomConditionCache, which stores ..
LLVM 에는 최적화를 위한 부가 데이터가 있다. value.h protected: /// Hold subclass data that can be dropped. /// /// This member is similar to SubclassData, however it is for holding /// information which may be used to aid optimization, but which may be /// cleared to zero without affecting conservative interpretation. unsigned char SubclassOptionalData : 7; SubClassOptionalData or disjoint disjoint는 or 최적화를 위한 ..