Skip to content

[CodeGen] Fix performance regression introduced in b05101b#161313

Merged
arichardson merged 1 commit into
mainfrom
users/arichardson/spr/codegen-fix-performance-regression-introduced-in-b05101b
Sep 30, 2025
Merged

[CodeGen] Fix performance regression introduced in b05101b#161313
arichardson merged 1 commit into
mainfrom
users/arichardson/spr/codegen-fix-performance-regression-introduced-in-b05101b

Conversation

@arichardson

Copy link
Copy Markdown
Member

The isNormalValueType = false flag was not set for this pseudo value
type, which caused significant size increases for some classes: the
size of the TargetLoweringBase class to 1.5 MB, because the size of
that class is quadratic in MVT::VALUETYPE_SIZE, and this commit
increased that from 256 to 504.

Reported by: abadams
Fixes: b05101b ("[TableGen, CodeGen, CHERI] Add support for the cPTR wildcard value type.")

Created using spr 1.3.8-beta.1
let isNormalValueType = false in {
// Pseudo valuetype mapped to the current CHERI capability pointer size.
// Should only be used in TableGen.
def cPTR : VTAny<503>;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated to this change but I wonder if we should we also renumber the other values and move this next to iPTR?

@nikic nikic left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@arichardson arichardson merged commit 8b445ab into main Sep 30, 2025
10 checks passed
@arichardson arichardson deleted the users/arichardson/spr/codegen-fix-performance-regression-introduced-in-b05101b branch September 30, 2025 15:16
llvm-sync Bot pushed a commit to arm/arm-toolchain that referenced this pull request Sep 30, 2025
The isNormalValueType = false flag was not set for this pseudo value
type, which caused significant size increases for some classes: the
size of the TargetLoweringBase class to 1.5 MB, because the size of
that class is quadratic in MVT::VALUETYPE_SIZE, and this commit
increased that from 256 to 504.

Reported by: abadams
Fixes: b05101b ("[TableGen, CodeGen, CHERI] Add support for the cPTR wildcard value type.")

Reviewed By: nikic

Pull Request: llvm/llvm-project#161313
mahesh-attarde pushed a commit to mahesh-attarde/llvm-project that referenced this pull request Oct 3, 2025
The isNormalValueType = false flag was not set for this pseudo value
type, which caused significant size increases for some classes: the
size of the TargetLoweringBase class to 1.5 MB, because the size of
that class is quadratic in MVT::VALUETYPE_SIZE, and this commit
increased that from 256 to 504.

Reported by: abadams
Fixes: b05101b ("[TableGen, CodeGen, CHERI] Add support for the cPTR wildcard value type.")

Reviewed By: nikic

Pull Request: llvm#161313
markrvmurray pushed a commit to markrvmurray/llvm-mc6809 that referenced this pull request Jun 14, 2026
The isNormalValueType = false flag was not set for this pseudo value
type, which caused significant size increases for some classes: the
size of the TargetLoweringBase class to 1.5 MB, because the size of
that class is quadratic in MVT::VALUETYPE_SIZE, and this commit
increased that from 256 to 504.

Reported by: abadams
Fixes: b05101b ("[TableGen, CodeGen, CHERI] Add support for the cPTR wildcard value type.")

Reviewed By: nikic

Pull Request: llvm/llvm-project#161313
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants