Fixed some uninitialized values, added some asserts/logic to avoid DeviceAPI::Parent.
Fixed some uninitialized values, added some asserts/logic to avoid DeviceAPI::Parent.


Former-commit-id: 75b9d4dd598d807bf82c960f03eb2ed5765390ed
darkbuck/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,darkbuck/Halide,Trass3r/Halide,Trass3r/Halide,darkbuck/Halide,darkbuck/Halide,darkbuck/Halide,Trass3r/Halide,Trass3r/Halide,Trass3r/Halide