File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
compiler/rustc_codegen_llvm/src Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -275,15 +275,17 @@ fn stackprotector_attr<'ll, 'tcx>(
275275 cx : & CodegenCx < ' ll , ' tcx > ,
276276 instance : ty:: Instance < ' tcx > ,
277277) -> Option < & ' ll Attribute > {
278- let fn_abi = cx. fn_abi_of_instance ( instance, ty:: List :: empty ( ) ) ;
279278 let sspattr = match cx. sess ( ) . stack_protector ( ) {
280279 StackProtector :: None => return None ,
281280 StackProtector :: All => AttributeKind :: StackProtectReq ,
282281
283282 StackProtector :: Rusty => {
283+ let fn_abi = cx. fn_abi_of_instance ( instance, ty:: List :: empty ( ) ) ;
284284 if cx. tcx . stack_protector . borrow ( ) . contains ( & instance. def_id ( ) )
285285 || matches ! (
286286 & fn_abi. ret. mode,
287+ // When a large-size variable is converted to a pointer and passed,
288+ // does meta_attrs always have to be Some(_)?
287289 PassMode :: Indirect { attrs: _, meta_attrs: _, on_stack: false }
288290 )
289291 {
You can’t perform that action at this time.
0 commit comments