Bug 271042 - VSX configure check fails when it should not
Summary: VSX configure check fails when it should not
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (show other bugs)
Version: 3.7 SVN
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-15 17:39 UTC by Maynard Johnson
Modified: 2011-04-15 23:09 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Patch to fix this bug (655 bytes, patch)
2011-04-15 17:39 UTC, Maynard Johnson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Maynard Johnson 2011-04-15 17:39:10 UTC
Created attachment 59013 [details]
Patch to fix this bug

Now that the initial (stage 1) POWER7 support patch has been accepted (see bug # 267630), I checked out the code from svn and tried to build it on a POWER7 system.  The config test for VSX failed with the following error:

	configure:7307: gcc -c -mvsx conftest.c >&5
	conftest.c: In function 'main':
	conftest.c:38:3: error: invalid 'asm': operand number missing after %-letter
	conftest.c:38:3: error: invalid 'asm': operand number missing after %-letter
	conftest.c:38:3: error: invalid 'asm': operand number missing after %-letter

The line in configure.in that it's complaining about is:
	__asm__ __volatile__("xsmaddadp %vs32, %vs32, %vs33" ::: "memory","cc");

The "%" should not be included, and we'd also need to add " -Wa,-regnames" to the compile line.  I'll attach a patch with this change, but alternatively, the line could simply be replaced with:

	__asm__ __volatile__("xsmaddadp 32, 32, 33" ::: "memory","cc");
Comment 1 Julian Seward 2011-04-15 23:09:31 UTC
>     __asm__ __volatile__("xsmaddadp 32, 32, 33" ::: "memory","cc");

I committed this as r11699.  Yell if it still doesn't work.