View Hoge.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package my.hoge; | |
public class Hoge { | |
public Hoge() | |
{ | |
} | |
public void printHoge(){ | |
System.out.println("Hoge!"); | |
} |
View HogeBack.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package my.hoge; | |
public class HogeBack { | |
private int num; | |
private native int callbackMethod(int num); | |
public void HogeBack() | |
{ | |
num = 0; |
View Hoge.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package scalatest; | |
class Hoge{ | |
def printHoge():Unit = println("Hoge in scala!") | |
def getHoge():String = "Hoge" | |
def add(i:Int, j:Int):Int = i + j | |
def getMsg(msg:String):String = "Hoget is " + msg | |
@native def callbackMethod(num:Int):Int = { 18} | |
def invokeMethod(num:Int):Int = { | |
println("Invoking Method"); |
View gist:1432135
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
int main() | |
{ | |
int _ecx = 0; | |
int is_aes = 0; | |
int is_avx = 0; | |
asm ( "movl $1, %eax;" ); |
View gist:1432141
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdint.h> | |
//#include <cpuid.h> | |
#include <emmintrin.h> | |
//#include <smmintrin.h> | |
typedef union { | |
__attribute__ ((aligned(16))) unsigned int i[4]; | |
__m128i m; | |
} m128i; |
View gist:1469945
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% make -f make_gcc.mak | |
gcc -W -O2 -Wall -Wno-unused -std=gnu99 -pedantic -shared -fPIC -o autoload/proc.so autoload/proc.c -lutil | |
autoload/proc.c:43:22: error: libutil.h: No such file or directory | |
autoload/proc.c: In function 'vp_pty_open': | |
autoload/proc.c:564: warning: implicit declaration of function 'openpty' | |
autoload/proc.c:571: warning: implicit declaration of function 'forkpty' | |
autoload/proc.c: In function 'vp_waitpid': | |
autoload/proc.c:750: warning: implicit declaration of function 'WIFCONTINUED' | |
autoload/proc.c: In function 'vp_decode': | |
autoload/proc.c:856: warning: array subscript has type 'char' |
View gist:1670149
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# include<stdio.h> | |
# define HOGE 1 | |
#ifdef HOGE | |
# define HUGA 2 | |
#else | |
# define HUGA 3 | |
#endif | |
int | |
main() |
View gist:1941350
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version='1.0'?> | |
<!-- This file was generated by SnoopyPro --> | |
<snoopyprolog> | |
<urb sequence="1"> | |
<function>GET_DESCRIPTOR_FROM_DEVICE</function> |
View gist:1941373
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version='1.0'?> | |
<!-- This file was generated by SnoopyPro --> | |
<snoopyprolog> | |
<urb sequence="1"> | |
<function>GET_DESCRIPTOR_FROM_DEVICE</function> |
View gist:1941481
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version='1.0'?> | |
<!-- This file was generated by SnoopyPro --> | |
<snoopyprolog> | |
<urb sequence="1"> | |
<function>GET_DESCRIPTOR_FROM_DEVICE</function> |
OlderNewer