Skip to content

how to compile the code in MacOS? #5

@songtianyi

Description

@songtianyi

gcc output

spectre.c:83:21: warning: passing 'int *' to parameter of type 'unsigned int *' converts between pointers to integer types with different sign [-Wpointer-sign]
                        time1 = __rdtscp(&junk); /* READ TIMER */
                                         ^~~~~
/Library/Developer/CommandLineTools/usr/bin/../lib/clang/8.1.0/include/ia32intrin.h:71:24: note: passing argument to parameter '__A' here
__rdtscp(unsigned int *__A) {
                       ^
spectre.c:85:21: warning: passing 'int *' to parameter of type 'unsigned int *' converts between pointers to integer types with different sign [-Wpointer-sign]
                        time2 = __rdtscp(&junk) - time1; /* READ TIMER & COMPUTE ELAPSED TIME */
                                         ^~~~~
/Library/Developer/CommandLineTools/usr/bin/../lib/clang/8.1.0/include/ia32intrin.h:71:24: note: passing argument to parameter '__A' here
__rdtscp(unsigned int *__A) {
                       ^

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions