From: Eric Biggers Date: Tue, 19 Jul 2016 16:00:17 +0000 (-0700) Subject: lzms_common.c: support x32 ABI in find_next_opcode_sse4_2() X-Git-Tag: v1.10.0~15 X-Git-Url: https://wimlib.net/git/?p=wimlib;a=commitdiff_plain;h=27bb33cf02e9a91b824fdad560e8233f1543ba39 lzms_common.c: support x32 ABI in find_next_opcode_sse4_2() --- diff --git a/src/lzms_common.c b/src/lzms_common.c index 380b7431..fb13a435 100644 --- a/src/lzms_common.c +++ b/src/lzms_common.c @@ -3,7 +3,7 @@ */ /* - * Copyright (C) 2013, 2014 Eric Biggers + * Copyright (C) 2013-2016 Eric Biggers * * This file is free software; you can redistribute it and/or modify it under * the terms of the GNU Lesser General Public License as published by the Free @@ -391,7 +391,11 @@ find_next_opcode_sse4_2(u8 *p) " pcmpestri $0x0, (%[p]), %[potential_opcodes] \n" " jnc 1b \n" "2: \n" + #ifdef __ILP32__ /* x32 ABI (x86_64 with 32-bit pointers) */ + " add %%ecx, %[p] \n" + #else " add %%rcx, %[p] \n" + #endif : [p] "+r" (p) : [potential_opcodes] "x" (potential_opcodes), "a" (6), "d" (16) : "rcx", "cc"