@@ -33,9 +33,9 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
3333 let ( begin, end) = crate :: mir:: naked_asm:: prefix_and_suffix ( cx. tcx ( ) , instance, item_data) ;
3434
3535 let mut template_vec = Vec :: new ( ) ;
36- template_vec. push ( rustc_ast:: ast:: InlineAsmTemplatePiece :: String ( begin) ) ;
36+ template_vec. push ( rustc_ast:: ast:: InlineAsmTemplatePiece :: String ( begin. into ( ) ) ) ;
3737 template_vec. extend ( template. iter ( ) . cloned ( ) ) ;
38- template_vec. push ( rustc_ast:: ast:: InlineAsmTemplatePiece :: String ( end) ) ;
38+ template_vec. push ( rustc_ast:: ast:: InlineAsmTemplatePiece :: String ( end. into ( ) ) ) ;
3939
4040 cx. codegen_global_asm ( & template_vec, & operands, options, line_spans) ;
4141 }
@@ -178,9 +178,6 @@ fn prefix_and_suffix<'tcx>(
178178 writeln ! ( begin, ".hidden {asm_name}" ) . unwrap ( ) ;
179179 }
180180 writeln ! ( begin, ".type {asm_name}, {function}" ) . unwrap ( ) ;
181- if let Some ( instruction_set) = attrs. instruction_set {
182- writeln ! ( begin, "{}" , instruction_set. as_str( ) ) . unwrap ( ) ;
183- }
184181 if !arch_prefix. is_empty ( ) {
185182 writeln ! ( begin, "{}" , arch_prefix) . unwrap ( ) ;
186183 }
@@ -203,9 +200,6 @@ fn prefix_and_suffix<'tcx>(
203200 if let Visibility :: Hidden = item_data. visibility {
204201 writeln ! ( begin, ".private_extern {asm_name}" ) . unwrap ( ) ;
205202 }
206- if let Some ( instruction_set) = attrs. instruction_set {
207- writeln ! ( begin, "{}" , instruction_set. as_str( ) ) . unwrap ( ) ;
208- }
209203 writeln ! ( begin, "{asm_name}:" ) . unwrap ( ) ;
210204
211205 writeln ! ( end) . unwrap ( ) ;
@@ -225,9 +219,6 @@ fn prefix_and_suffix<'tcx>(
225219 writeln ! ( begin, ".scl 2" ) . unwrap ( ) ;
226220 writeln ! ( begin, ".type 32" ) . unwrap ( ) ;
227221 writeln ! ( begin, ".endef {asm_name}" ) . unwrap ( ) ;
228- if let Some ( instruction_set) = attrs. instruction_set {
229- writeln ! ( begin, "{}" , instruction_set. as_str( ) ) . unwrap ( ) ;
230- }
231222 writeln ! ( begin, "{asm_name}:" ) . unwrap ( ) ;
232223
233224 writeln ! ( end) . unwrap ( ) ;
0 commit comments