Efficient mesh instantiation

Is there a effecient way to place 10000 meshes on a terrain, without making the game lag. This is because I want to make a terrain with grass on it, so I would need to instantiate around 10000 meshes for a decent look.
Note: The terrain is a mesh and is generated at run-time so I can’t use the built-in tools…

Have already made a scatter tool which did what you want.
Bad idea ^^'.
Instancing a lot of gameObject slow down considerately the framerate.

However, if you can’t create a “single” mesh for your all grass, you could try to manage yourself by saving each mesh transformation matrix in a single array.
After, in Update() for exemple, drawing yourself via DrawMesh (async drawing with full rendering pipeline) or DrawMeshNow (sync drawing without unity rendering pipeline).

With this, you never instanciate anything, just yield the creation of all the matrix.

A better answer is to group grass in the same mesh. This way you create one mesh spawning many grass instances (like a sector) in a single object. Each grass might consist just of two triangles but you are free to create as many triangles as far away from each other as needed.

If you putting you combine your different grass textures in a clever way you can even put many different grass and flower combinations closely (or with some space in between) together so you can use a single pair of triangles to draw two or more grass groups together (if you use real 3d to draw the grass).

Also remember creating 10000 times a mesh is expensive, creating 10000*2 triangles within a mesh is cheap but also creating 10000 times an object is expensive but having 10000 existing objects being moved as necessary (grass that is not visible any more gets reused by just moving it to a new location).

This way you can have almost instant appearing grass without the costs of creating too many objects.