Skip to content

No fastcall attribute in POWER platform #35083

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 9, 2020
Merged

Conversation

ayappanec
Copy link
Contributor

Compiling the development branch of pandas fail in AIX.

pandas/_libs/src/ujson/lib/ultrajsonenc.c:397:1: error: ‘fastcall’ attribute directive ignored [-Werror=attributes]
Buffer_AppendShortHexUnchecked(char *outputOffset, unsigned short value) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pandas/_libs/src/ujson/lib/ultrajsonenc.c:726:59: error: ‘fastcall’ attribute directive ignored [-Werror=attributes]
char *end) {
^~~~
cc1: all warnings being treated as errors

The fastcall attribute is not available in POWER platform also.

@WillAyd
Copy link
Member

WillAyd commented Jul 1, 2020

FWIW I would be OK with removing this altogether. AFAIK it's only for i386 platforms which we don't really care to optimize at this point

@WillAyd WillAyd added IO JSON read_json, to_json, json_normalize Build Library building on various platforms and removed IO JSON read_json, to_json, json_normalize labels Jul 1, 2020
@ayappanec
Copy link
Contributor Author

FWIW I would be OK with removing this altogether. AFAIK it's only for i386 platforms which we don't really care to optimize at this point

Okay, so shall i remove it altogether in this PR ?

@WillAyd
Copy link
Member

WillAyd commented Jul 1, 2020

Yea let's go ahead and remove it. If you can run the JSON benchmarks after than and post the results would help confirm

@ayappanec
Copy link
Contributor Author

Not sure how to run those JSON benchmarks

@WillAyd
Copy link
Member

WillAyd commented Jul 1, 2020

Check this guide:

https://pandas.pydata.org/pandas-docs/stable/development/contributing.html#running-the-performance-test-suite

You can use the -b json switch at the end to limit the results to that module

@@ -108,11 +108,7 @@ typedef uint32_t JSUINT32;

#define FASTCALL_MSVC

#if !defined __x86_64__ && !defined __aarch64__
#define FASTCALL_ATTR __attribute__((fastcall))
#else
#define FASTCALL_ATTR
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you can remove this altogether would be preferable. No need for an empty define

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing the empty defines also needs lot of cleanup in ultrajsondec.c . Otherwise there will be compilation problems. And also not sure about the fastcall defines under _WIN32 .

@jreback jreback added this to the 1.1 milestone Jul 2, 2020
@jreback
Copy link
Contributor

jreback commented Jul 2, 2020

looks fine @WillAyd merge when good

@WillAyd
Copy link
Member

WillAyd commented Jul 6, 2020

@ayappanec can you remove all occurrences of this macro instead of the empty define?

@ayappanec
Copy link
Contributor Author

JSON_Benchmarks.txt
Attaching the JSON benchmarks results here

@jreback
Copy link
Contributor

jreback commented Jul 7, 2020

@ayappanec can you run vs the master commit, e.g. https://pandas.pydata.org/docs/dev/development/contributing.html#running-the-performance-test-suite, you need asv continuous

@ayappanec
Copy link
Contributor Author

@ayappanec can you run vs the master commit, e.g. https://pandas.pydata.org/docs/dev/development/contributing.html#running-the-performance-test-suite, you need asv continuous

Looks like hdf5 needs to be installed . I never encountered hdf5 before

@ayappanec
Copy link
Contributor Author

Installed HDF5 but now it fails with llvmlite build.

       raise RuntimeError("unsupported platform: %r" % (sys.platform,))
   RuntimeError: unsupported platform: 'aix6'

Looks like the asv benchmark testing needs some pre-requisites which has compilation issues in AIX .

Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@ayappanec
Copy link
Contributor Author

Any update on getting this merged ?

@jreback jreback merged commit d536440 into pandas-dev:master Jul 9, 2020
@jreback
Copy link
Contributor

jreback commented Jul 9, 2020

thanks @ayappanec

@ayappanec
Copy link
Contributor Author

@WillAyd @jreback Thanks for the support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Library building on various platforms
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants