Where are the Arduino Due registers? Having most of my experience on ATmega chips, and just starting up with Arduino (to reduce hardware development time) I'm happy to see that the usual registers such as TIMSK0, PCICR, TCNT1H and others can be used from the Arduino IDE just as they appear in the Atmel datasheet.

Migrating to the Arduino Due, however, came with a shock: the registers specified in the datasheet of the Cortex-M3 are not recognized by the Arduino IDE (although I downloaded the extension necessary for being able to select the Due). I wanted to do something very simple, like configuring a timer. I found TC_CMR0 in the datasheet, but the Arduino IDE doesn't recognize it. I found an example using the Arduino Due with timers in an obscure forum, and they used REG_PWM_CMR0. I tried it in the Arduino IDE, and it was accepted by the compiler.

I searched the Arduino and other forums, and couldn't find any hint whatsoever about the naming of the registers. Why are the names of the registers different? And can I find a conclusive documentation about the register names, or am I doomed to research each and every one of the hundreds of registers individually?
There are a few files in the Arduino Due core that you should have a look at. They give great insight into the SAM register set up; variant.h, variant.cpp and chip.h

After that you can dive into the libsam and the many components (include/source). 

The SAM code has a very different structure and style compared to AVR. 

Cheers!