Skip to content

Instantly share code, notes, and snippets.

@pcpratts
pcpratts / sync_test.cu
Created January 18, 2014 21:35
CUDA __syncthreads not operating as hoped
#include <stdio.h>
__global__ void sync_test(void)
{
printf("a\n");
if(threadIdx.x == 0){
__syncthreads();
__syncthreads();
} else {
@pcpratts
pcpratts / patch.java
Created February 11, 2013 13:31
patch to make invalid cast work
diff --git a/src/soot/jimple/toolkits/typing/fast/UseChecker.java b/src/soot/jimple/toolkits/typing/fast/UseChecker.java
index 5aa6c65..4472680 100644
--- a/src/soot/jimple/toolkits/typing/fast/UseChecker.java
+++ b/src/soot/jimple/toolkits/typing/fast/UseChecker.java
@@ -184,9 +184,6 @@ public class UseChecker extends AbstractStmtSwitch
else if ( rhs instanceof ArrayRef )
{
this.handleArrayRef((ArrayRef)rhs, stmt);
- if (!(tlhs instanceof BottomType || tlhs instanceof BottomType)) {
- ((ArrayRef)rhs).setBase((Local)this.uv.visit(((ArrayRef)rhs).getBase(), tlhs.makeArrayType(), stmt));