From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/8604 Path: news.gmane.org!not-for-mail From: Alex Dowad Newsgroups: gmane.linux.lib.musl.general Subject: [PATCH 2/5] When generating CFI for i386 asm, don't mistake an FDIV instruction for DIV Date: Fri, 2 Oct 2015 13:32:33 +0200 Message-ID: <1443785556-27473-2-git-send-email-alexinbeijing@gmail.com> References: <1443785556-27473-1-git-send-email-alexinbeijing@gmail.com> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1443785619 30939 80.91.229.3 (2 Oct 2015 11:33:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 2 Oct 2015 11:33:39 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-8616-gllmg-musl=m.gmane.org@lists.openwall.com Fri Oct 02 13:33:39 2015 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1Zhyah-0004Bs-SN for gllmg-musl@m.gmane.org; Fri, 02 Oct 2015 13:33:31 +0200 Original-Received: (qmail 16367 invoked by uid 550); 2 Oct 2015 11:33:25 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 15656 invoked from network); 2 Oct 2015 11:32:56 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:in-reply-to:references; bh=mEG8I802IBwGiIOZOAPe4r5lBAkXXx4YKbOaLA8rv18=; b=szM3WNeyby2IaM+RUhEHfGafB76Nbdeox+kNbhEgjjXix/BqgJ7zWTghHVoi/MVNU7 yygmkkYg4AhELpUbyH2f+SICO7LvaOtATSGmGhV0/NwjjiHVJilzlsv/8KygJW5uuFNQ QaujVdmiFqYkyyg8uEwfSUXT8tFm8WifT6X3xYyWUbLfr3fxSKrrX+cm2bHPhuap4Zis M5IXLHGXe4TuHSYq/k1rWqcGKH1aZtxMf3HkVUo25YKJpkL4SRRNx69snzPm7D6mGSmg Q3+1hXeiQLeob4phiZW7R0l9R0eyE0z15r8qXfZ7T1dqWnXGD3T2ABJIc3Yt0+YZOJtr RuTg== X-Received: by 10.180.79.5 with SMTP id f5mr3543061wix.79.1443785565419; Fri, 02 Oct 2015 04:32:45 -0700 (PDT) X-Mailer: git-send-email 2.0.0.GIT In-Reply-To: <1443785556-27473-1-git-send-email-alexinbeijing@gmail.com> Xref: news.gmane.org gmane.linux.lib.musl.general:8604 Archived-At: ...that would cause the script to erroneously conclude that the values of EAX and EDX have been overwritten. Probably won't make a difference, but it's just as well to get it right... --- tools/add-cfi.i386.awk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/add-cfi.i386.awk b/tools/add-cfi.i386.awk index b8bdd7f..2da1899 100644 --- a/tools/add-cfi.i386.awk +++ b/tools/add-cfi.i386.awk @@ -190,7 +190,7 @@ function trashed(register) { } /i?mul [^,]*$/ { trashed("eax"); trashed("edx") } /i?mul %e(ax|bx|cx|dx|si|di|bp),/ { trashed(get_reg1()) } -/i?div/ { trashed("eax"); trashed("edx") } +/^i?div/ { trashed("eax"); trashed("edx") } /(dec|inc|not|neg|pop) %e(ax|bx|cx|dx|si|di|bp)/ { trashed(get_reg()) } /cpuid/ { trashed("eax"); trashed("ebx"); trashed("ecx"); trashed("edx") } -- 2.0.0.GIT