1. A computer-implemented method for processing one or more XML documents, where the processing includes a plurality of stylesheets using an abstract machine, the method comprising: reading a stylesheet of the plurality of stylesheets; parsing at least some Xpath expressions within the plurality of stylesheets into a respective tree of nodes; annotating the respective tree of nodes of the Xpath expressions with a data type of the Xpath expression; compiling the respective annotated tree of nodes of the Xpath expressions into a set of abstract machine instructions specialized for stylesheet processing, wherein the set of abstract machine instructions comprises a plurality of blocks of abstract machine instructions for the compiled stylesheet and includes a backtracking abstract machine instruction for each block of the plurality of blocks; executing the instructions on an abstract machine to produce an output document, wherein the abstract machine uses a plurality of types of contiguous memory storage to match requirements of the stylesheet processing and wherein the plurality of types of contiguous memory storage includes a code stack, a heap stack and a transform allocator; resetting the code stack and the heap stack upon processing completing of each block of the plurality of blocks; and calling a block of the plurality of blocks via a pattern match for imports which calls a template that can match with a lower import precedence than a current template, wherein the executing the abstract machine instruction set in the abstract machine further comprises processing a representation of the one or more XML documents.