Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/CUDApp/blob/main/tests/attn_host_diff.c # CUDApp CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `CUDApp / tests / attn_host_diff.c` 59 lines · 3194 bytes Raw Blame History 1 /* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception */ 2 #include 3 #include 4 #include 5 #include 6 #include 7 uint64_t om_plan(uint64_t[32],uint32_t);uint64_t c_plan(uint64_t[32],uint32_t); 8 size_t om_check(uint32_t,const uint32_t*,const uint32_t*,size_t);size_t c_check(uint32_t,const uint32_t*,const uint32_t*,size_t); 9 uint64_t om_clock(uint64_t,uint64_t);uint64_t c_clock(uint64_t,uint64_t); 10 #define REQUIRE(x) do{if(!(x)){fprintf(stderr,"FAIL line %d: %s\n",__LINE__,#x);return 1;}}while(0) 11 static int policy(void){ 12 const uint32_t edge[]={0,1,2,3,4,15,16,17,31,32,33,63,64,65,127,128,129,255,256,257,1023,1024,1025,UINT32_MAX-1,UINT32_MAX}; 13 for(size_t i=0;i0);w[n-1]^=1;} 44 for(size_t i=0;i1){w[0]=1;w[n-1]=0;REQUIRE(om_check(2,w,w,n)==c_check(2,w,w,n)&&om_check(2,w,w,n)>0);} 47 for(size_t i=0;i