[PATCH] D139395: Add support for integer types normalization

2022-12-06 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle added a comment. FYI, I'll still add (hopefully today) documentation for the new `-fsanitize-cfi-icall-normalize-integers` option and compression for these types. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/

[PATCH] D139395: Add CFI integer types normalization

2022-12-07 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 481016. rcvalle added a comment. Updated tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2022-12-12 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 482327. rcvalle added a comment. Added ".normalized" suffix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2022-12-06 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 480700. rcvalle retitled this revision from "Add support for integer types normalization" to "Add CFI integer types normalization". rcvalle edited the summary of this revision. rcvalle added a comment. Added documentation Repository: rG LLVM Github

[PATCH] D139395: Add CFI integer types normalization

2022-12-06 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 480773. rcvalle added a comment. Added compression Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2022-12-06 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 480775. rcvalle added a comment. Fixed comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2022-12-13 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 482699. rcvalle added a comment. Updated tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2022-12-13 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 482708. rcvalle added a comment. Added KCFI support Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add support for integer types notmalization

2022-12-05 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle created this revision. Herald added a subscriber: JDevlieghere. Herald added a project: All. rcvalle requested review of this revision. Herald added subscribers: cfe-commits, MaskRay. Herald added a project: clang. This commit adds support for normalizing integer types as vendor extended

[PATCH] D139395: Add support for integer types normalization

2022-12-05 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 480349. rcvalle retitled this revision from "Add support for integer types notmalization" to "Add support for integer types normalization". rcvalle added a comment. Fixed typo in commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D139395: Add CFI integer types normalization

2022-12-12 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle added inline comments. Comment at: clang/lib/AST/ItaniumMangle.cpp:2952 + // uu + if (NormalizeIntegers && T->isInteger()) { +if (T->isSignedInteger()) { pcc wrote: > `isInteger()` will return true for enums, but only if they are complete. This >

[PATCH] D139395: Add CFI integer types normalization

2022-12-12 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle added a comment. I elaborated on the reasons why not use a generalized encoding in the design document in the tracking issue https://github.com/rust-lang/rust/issues/89653. The tl;dr; is that it will result in less comprehensive protection by either using a generalized encoding for all

[PATCH] D139395: Add CFI integer types normalization

2023-01-20 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle marked an inline comment as done. rcvalle added inline comments. Comment at: clang/docs/ControlFlowIntegrity.rst:241 + +``-fsanitize-cfi--icall-experimental-normalize-integers`` +- samitolvanen

[PATCH] D139395: Add CFI integer types normalization

2023-01-20 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 491013. rcvalle added a comment. Fixed typo Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst clang/docs/UsersManual.rst

[PATCH] D139395: Add CFI integer types normalization

2023-01-20 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 490976. rcvalle added a comment. Mark as experimental Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2023-01-31 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 493732. rcvalle marked an inline comment as done. rcvalle added a comment. Changed as per review Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files:

[PATCH] D139395: Add CFI integer types normalization

2023-01-31 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle marked 4 inline comments as done. rcvalle added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:1694 + getCXXABI().getMangleContext().mangleTypeName( + T, Out, !!getCodeGenOpts().SanitizeCfiICallNormalizeIntegers); + pcc wrote: >

[PATCH] D139395: Add CFI integer types normalization

2023-02-07 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 495718. rcvalle added a comment. Fixed use of uninitialized value Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst

[PATCH] D139395: Add CFI integer types normalization

2023-02-08 Thread Ramon de C Valle via Phabricator via cfe-commits
rcvalle updated this revision to Diff 495860. rcvalle added a comment. Fixed initialization order warning Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139395/new/ https://reviews.llvm.org/D139395 Files: clang/docs/ControlFlowIntegrity.rst