- 
                Notifications
    You must be signed in to change notification settings 
- Fork 13.9k
          Use LLVMIntrinsicGetDeclaration to completely remove the hardcoded intrinsics list
          #142521
        
          New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| @bors2 try @rust-timer queue | 
      
        
              This comment has been minimized.
        
        
      
    
  This comment has been minimized.
Use `LLVMIntrinsicGetDeclaration` to completely remove the hardcoded intrinsics list Follow-up to #142259 This also needs a rustc-perf run, because `Intrinsic::getType` can be expensive `@rustbot` label A-LLVM A-codegen T-compiler r? `@workingjubilee` cc `@nikic`
      
        
              This comment has been minimized.
        
        
      
    
  This comment has been minimized.
| hum. | 
| 💔 Test failed 
 | 
| interesting segfault, I have a suspicion that this is due to  | 
10a73c9    to
    7504607      
    Compare
  
    | ah, so it was due to a mistake in the last PR, it didn't have any type parameters for  | 
| Oh, distressing. | 
| @bors2 try | 
Use `LLVMIntrinsicGetDeclaration` to completely remove the hardcoded intrinsics list Follow-up to #142259 This also needs a rustc-perf run, because `Intrinsic::getType` can be expensive `@rustbot` label A-LLVM A-codegen T-compiler r? `@workingjubilee` cc `@nikic`
Use `LLVMIntrinsicGetDeclaration` to completely remove the hardcoded intrinsics list Follow-up to #142259 This also needs a rustc-perf run, because `Intrinsic::getType` can be expensive `@rustbot` label A-LLVM A-codegen T-compiler r? `@workingjubilee` cc `@nikic`
| is bors ghosting us now? | 
| oh no, the latency. | 
| @bors2 try cancel | 
| Try build cancelled. Cancelled workflows: | 
| AHA, MY PLAN WAS TO TEST THE CANCEL FUNCTION ALL ALONG | 
| that is some serious difference in latency. | 
| ☀️ Try build successful - checks-actions | 
      
        
              This comment has been minimized.
        
        
      
    
  This comment has been minimized.
| Finished benchmarking commit (f92eca7): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy. 
 Max RSS (memory usage)Results (secondary 0.2%)A less reliable metric. May be of interest, but not used to determine the overall result above. 
 CyclesThis benchmark run did not return any relevant results for this metric. Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 758.463s -> 757.066s (-0.18%) | 
| Yay! No perf regression ❤️ | 
|  | ||
| intrinsics: | ||
| RefCell<FxHashMap<(&'static str, SmallVec<[&'ll Type; 2]>), (&'ll Type, &'ll Value)>>, | ||
| RefCell<FxHashMap<(Cow<'static, str>, SmallVec<[&'ll Type; 2]>), (&'ll Type, &'ll Value)>>, | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did this become a Cow because previously everything was indirected via the &'static strs in declare_intrinsic, and now no longer is?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just wanted to reduce some allocations (because most intrinsic names are string literals, but some are generated by format!). String would work as well. Should I change it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be fine.
7504607    to
    3dc8ebc      
    Compare
  
    There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
| There is one more place where we should use  | 
| 
 Yes, I believe this is guaranteed. | 
| Nice, then I am changing that too edit: I mean using  | 
3dc8ebc    to
    a9500d6      
    Compare
  
    | @bors r+ | 
| @bors r=nikic,workingjubilee | 
| 💡 This pull request was already approved, no need to approve it again. 
 | 
| ☀️ Test successful - checks-actions | 
| What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing e314b97 (parent) -> 68ac5ab (this PR) Test differencesNo test diffs found Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
    test-dashboard 68ac5abb067806a88464ddbfbd3c7eec877b488d --output-dir test-dashboardAnd then open  Job duration changes
 How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance | 
| Finished benchmarking commit (68ac5ab): comparison URL. Overall result: ❌✅ regressions and improvements - no action needed@rustbot label: -perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy. 
 Max RSS (memory usage)This benchmark run did not return any relevant results for this metric. CyclesResults (primary 2.2%, secondary -9.4%)A less reliable metric. May be of interest, but not used to determine the overall result above. 
 Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 756.881s -> 757.272s (0.05%) | 
Follow-up to #142259
This also needs a rustc-perf run, because
Intrinsic::getTypecan be expensive@rustbot label A-LLVM A-codegen T-compiler
r? @workingjubilee
cc @nikic