View Issue Details

IDProjectCategoryView StatusLast Update
0035701FPCOtherpublic2019-06-22 15:31
ReporterJ. Gareth MoretonAssigned ToJonas Maebe 
PrioritylowSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Platformi386 and x86_64OSMicrosoft WindowsOS Version10 Professional
Product Version3.3.1Product Buildr42196 
Target VersionFixed in Version3.3.1 
Summary0035701: [Test] Test "tests/webtbs/tw13294" is possibly invalid
DescriptionThe test specified checks to see if MOVD works properly when using XMM registers. However, the variable that it is reading and writing to is 64-bit, whereas MOVD specifically handles 32-bit data (it's in the "D" in the mnemonic). As thus, when the patches from 0035700 are applied, the test fails to compile on both i386 and x86_64 with the following errors:

tw13294.pp(12,7) Error: Asm: [movd reg??,mem64] invalid combination of opcode and operands
tw13294.pp(13,7) Error: Asm: [movd mem64,reg??] invalid combination of opcode and operands

This, in my eyes, is a correct failure, since the variables are of type Int64. Given the nature of the test, either it needs to be rewritten to use LongInts, or new variables of type LongInt map onto a and b using "absolute", and those passed into the assembler blocks. It's also indictive of a possible test bug anyway because the upper 32 bits of b may not be initialised.
Steps To ReproduceAttempt to compile the test with the patches from 0035700 applied.
Additional InformationWhen using similar assembly language written under Intel mode, the memory operand size can be overridden with "DWORD PTR", allowing the test to compile and run as expected. I am not certain what the equivalent trick in AT&T mode is, because using "movdl" still raises the same errors (which might indicate another compiler bug).
Tags32-bit, 64-bit, assembler, compiler, i386, test, x86, x86_64-win64
Fixed in Revision42268
FPCOldBugId
FPCTarget-
Attached Files

Relationships

child of 0035700 new [Assembler] Fix for SSE/AVX instructions with 32- and 64-bit operands 

Activities

Jonas Maebe

2019-06-22 15:31

manager   ~0116845

Thanks, I've fixed the test.

Issue History

Date Modified Username Field Change
2019-06-10 22:51 J. Gareth Moreton New Issue
2019-06-10 22:51 J. Gareth Moreton Relationship added child of 0035700
2019-06-14 05:44 J. Gareth Moreton Tag Attached: test
2019-06-14 05:44 J. Gareth Moreton Tag Attached: assembler
2019-06-14 05:44 J. Gareth Moreton Tag Attached: x86
2019-06-18 04:24 J. Gareth Moreton Description Updated View Revisions
2019-06-18 04:24 J. Gareth Moreton FPCTarget => -
2019-06-18 04:24 J. Gareth Moreton Tag Attached: compiler
2019-06-18 04:24 J. Gareth Moreton Tag Attached: 32-bit
2019-06-18 04:24 J. Gareth Moreton Tag Attached: i386
2019-06-18 04:25 J. Gareth Moreton Priority normal => low
2019-06-18 04:25 J. Gareth Moreton Tag Attached: x86_64-win64
2019-06-18 04:25 J. Gareth Moreton Tag Attached: 64-bit
2019-06-22 15:31 Jonas Maebe Assigned To => Jonas Maebe
2019-06-22 15:31 Jonas Maebe Status new => resolved
2019-06-22 15:31 Jonas Maebe Resolution open => fixed
2019-06-22 15:31 Jonas Maebe Fixed in Version => 3.3.1
2019-06-22 15:31 Jonas Maebe Fixed in Revision => 42268
2019-06-22 15:31 Jonas Maebe Note Added: 0116845