This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] S390: Hotpatching fixes.
- From: Jakub Jelinek <jakub at redhat dot com>
- To: gcc-patches at gcc dot gnu dot org, Andreas Krebbel <krebbel at linux dot vnet dot ibm dot com>
- Date: Mon, 9 Mar 2015 12:30:05 +0100
- Subject: Re: [PATCH] S390: Hotpatching fixes.
- Authentication-results: sourceware.org; auth=none
- References: <20150305124019 dot GA6266 at linux dot vnet dot ibm dot com> <20150309112221 dot GA4801 at linux dot vnet dot ibm dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Mon, Mar 09, 2015 at 12:22:21PM +0100, Dominik Vogt wrote:
> @@ -5308,34 +5309,14 @@ s390_asm_output_function_label (FILE *asm_out_file, const char *fname,
> stored directly before the label without crossing a cacheline
> boundary. All this is necessary to make sure the trampoline code can
> be changed atomically. */
> + function_alignment = MAX (8, DECL_ALIGN (decl) / BITS_PER_UNIT);
> + if (! DECL_USER_ALIGN (decl))
> + function_alignment = MAX (function_alignment,
> + (unsigned int) align_functions);
Wrong formatting. function_alignment should be only 2 columns to the right
from if.
> +(define_insn "nop_6_byte"
> + [(unspec_volatile [(const_int 0)] UNSPECV_NOP_6_BYTE)]
> + ""
Shouldn't this use "TARGET_ZARCH" condition?
BTW, have you tried say:
__attribute__((hotpatch (0, 6))) void foo (void) { __builtin_unreachable (); }
?
Have you verified there never are real instructions before
NOTE_INSN_FUNCTION_BEG?
Jakub