[P3400 ROM Development] krazy_about_technology:
Hmm now these are some lengthy ones :D

1. XIP or Execute In Place is actually a mechanism in Windows mobile or rather the CE OS on top of which Windows mobile is built, which allows it to run critical parts of the OS, including the kernel, directly from the storage without loading them into the RAM, thereby saving RAM and allowing these parts to start and run faster. XIP requires special flash memory hardware which i have forgot about, whether it was Nand Flash or Nor. One of these can XIP and has great reading speeds but slower write speeds, other cannot XIP but has good read and write speeds. Most of todays phones mostly have hybrid type of flash memory in which a part of it is made with XIP capable material and the rest as non XIP. Thats the reason why Gene ROMs must be greater than 50 MB in size as before that the area is XIP capable one, which has to be locked as read only.

By contrast if you look at the regular programs, in computer as well as mobile, they require loading into RAM due to some reasons. The obivious reason is that the secondry storage on which they are stored is many times slower and also gets more wear and tear with read and write cycles in comparison to RAM. So what happens is that the executable files are designed in such a way that they must be loaded into RAM for execution. This is becuase, every executable has a header area which contains tables of addresses to the functions or subroutines, resources etc inside the executable. These addresses are relative to an imaginary adress called Base Address of the executable which is fixed for windows executables. When the file is loaded into memory, this base address is given a real address in RAM and all the other addresses are relocated according to it and hence they become accessible to OS to run.

The executables in the XIP, on the other hand have their headers ripped off and have given constant addresses from where they are loaded by the device firmware. Thats why only a small and fixed no of files are XIPed, not all. So they dont load into RAM and run from their place by firmware.

Now it makes the fact very clear that since the files are loaded by firmware, they have different "assumed" addresses for different phones. Porting an XIP means to adjust the address of files in the XIP in accordance to the target device firmware and removing any extra files that are in the new one, that came from different device. In this process, in the XIP taken from original ROM, only the essential files that make up the kernel of new OS as well as some other important parts are replaced by the files from new ROM's XIP and other device specific files are left as it is from the original ROM's XIP. After that the new files are relocated according to the target device by comparing them to original XIP. Then this XIP is compiled into a XIP.bin file using buildXIP.exe utility which completes the porting process.

And BTW, XIP also defines the size of page pool although i dont know where.

You cannot have XIP from one rom and rest of the files from other. Files in XIP are part of the same build of the OS so the SYS folder and XIP must be from same ROM. OEM can be made according to your choice, although OEMDrivers, OEMOperators, OEMVersion and most of the times OEMApps folders are taken from the original ROM as these contains drivers and essential utilities specific to your device.

2. Keyboards in my rom are in form of packages in OEM so you can remove them easily, look for ezinput packages. i think there are 3 of them that make up the complete package.

3. The default WM 6.1 dialer is part of the OS and cannot be removed. All other dialers like the original GENE dilaer, the PhoneCanvas used in newer htc phones like Opal and Diamond as well as the HTC Touch (ELF) dialers, all work on top of it by extending it with dlls and then skinning it. So if the ROM has one of these, you can removed them from OEM folder, otherwise, just copy a package containing one of these dialers and dialer skins and build your rom. You can enable and disable the skinned dialer by using utilities like Advance Configuration Tool etc. But complete dialer skins with smart dial and all are a bit hard to find.