checking array out of bounds on shared. -shared-mem-size supported.