I used only the "DS18x20" example sketch.
But you said you got an error regarding IO registers? This means your IDE is using the "normal" OneWire" library located under your "Documents\arduino\libraries" folder, instead of the modified library located in your arduino program folder... (for me, this would be c:\arduino-1.6.1-esp8266\libraries\OneWire for the modified library, and NOT c:\users\dennis\documents\arduino\libraries\OneWire which is the wrong one!!).
(you can see which library path is used, when you enable verbose output for compiling in the arduino IDE, and check the output when testing the sketch). If the library used is the original one, it will fail. In this case I recommend to remove the original "OneWire" folder from your user arduino folder, then restart IDE - and it will use the modified OneWire library.
regards