File: issuephp3.c

package info (click to toggle)
chibicc 1.0.23.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,832 kB
  • sloc: ansic: 62,911; sh: 275; makefile: 92
file content (16 lines) | stat: -rw-r--r-- 290 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "test.h"

int main(void) {
  unsigned int eax, edx;

  __asm__ __volatile__ (
    ".byte 0x0f, 0x01, 0xd0"   // xgetbv
    : "=a"(eax), "=d"(edx)
    : "c"(0)
  );

  printf("xgetbv eax: %08x edx: %08x\n", eax, edx);
  ASSERT(7, eax);
  ASSERT(0, edx);
  return 0;
}