1. A wavefield simulation method that comprises: specifying a kernel of operations to be applied at each point in a space; representing the kernel as a platform-agnostic directed acyclic graph with nodes representing results of operations and with edges representing dependencies; and for each of multiple implementation platforms: deriving from the platform-agnostic graph a customized graph for the implementation platform, wherein said deriving includes performing graph-based optimization; translating the customized graph into configuration information for the implementation platform; supplying the configuration information to the implementation platform to obtain a wavefield simulator; and employing the wavefield simulator to repeatedly apply said kernel of operations to each point in the space with specified input or output signals.