From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <643973b9c0074170145322ddf82ea07c@gmx.de> Date: Fri, 24 May 2013 23:29:27 +0200 From: cinap_lenrek@gmx.de To: 9fans@9fans.net MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: [9fans] broken floating point exceptions and fpregs Topicbox-Message-UUID: 5b5cf558-ead8-11e9-9d60-3106f5b1d025 the sse change broke floating point exception handling. from /sys/src/9/pc/main.c:^matherror() /* * save floating point state to check out error */ fpenv(&up->fpsave); mathnote(); this is wrong, because fpenv() will store the enviroment in x87 format, but mathnote() uses mathstate() which intreprets the FPsave structure depending on if sse was enabled or not. a fix for this was just commited in 9front which passes the status word and fppc explicitely to mathnode() and uses mathnote(up->fpsave.status, up->fpsave.pc); in matherror() and the values extracted by mathstate() in mathemu(). the 2nd problem is how we'r going to handle the fpregs file in devproc. as this change changes the format. fpr() in acid returns garbage right now. any thoughts on it how to move forward on this? -- cinap