I don't see why portability is a concern, since gcc and the other modern compilers deal in ieee-754 floats, like go, so if c.sizeof(double) != 8, then iirc, the c doubles would have to have even more precision, but in any case you can panic. Otherwise the memory layout is identical, you can construct a float64 slice header with the length and cap set to `c.sizeof(thearray)/c.sizeof(double)` and the go gc will either inherit responsibility for the original alloc, or you can use finalizer's on the go side, and/or extra references to ensure the data is never gc'd, depending on what you want.
Just be sure that the original c data is not stack allocated.