Hi Martin, I can confirm the ICE.
integer(C_SIGNED_CHAR), dimension(size(bytes_raw,kind=pLongInt)-int(headerLen,pLongInt)) :: bytes
integer(C_SIGNED_CHAR), allocatable :: bytes(:) allocate(bytes(size(bytes_raw,dim=1,kind=pLongInt)-int(headerLen,pLongInt)))
let the ICE disappear. I'm not sure, whether it helps you, because the context is not clear to me and you maybe know that already and wanted just to inform us.
However, an ICE should always be reported and a ticket be opened. All users will hopefully benefit from it
Agree re: the ICE, it's great you're reporting it, it helps everyone.
Re: a workaround, can you consider an alternative as shown below?
integer(C_SIGNED_CHAR), dimension(chunkLen) :: bytes
Something to keep in mind always is what's easier for a future reader of your code (which may be you yourself in a new incarnation which is basically any moment following the time you author your first draft) is also often easier on the processor (compiler).