Get the correct buffer layout for given variable type.