### Godot version

4.1.1

### System information

Meta Quest 2 - GLES3

### Issue description

When writing VR applications on Godot 4 using gl_compatibility, skeleton-driven meshes like hands are often rendered corrupted, or sometimes update slowly.

### Steps to reproduce

The godot-xr-tools demo projects have these issues in the climbing/gliding and pointer-demo scenes if the project is switched to gl_compatibility mode and run on a mobile VR headset.

### Minimal reproduction project

The godot-xr-tools demo project has been the testing project for this issue.
return skeleton_owner.allocate_rid();
}
void MeshStorage::skeleton_initialize(RID p_rid) {
	skeleton_owner.initialize_rid(p_rid, Skeleton());
}
void MeshStorage::skeleton_free(RID p_rid) {
	_update_dirty_skeletons();
	skeleton_allocate_data(p_rid, 0);
	Skeleton *skeleton = skeleton_owner.get_or_null(p_rid);
	skeleton->dependency.deleted_notify(p_rid);
	skeleton_owner.free(p_rid);
}
void MeshStorage::_skeleton_make_dirty(Skeleton *skeleton) {
	if (!skeleton->dirty) {
		skeleton->dirty = true;
		skeleton->dirty_list = skeleton_dirty_list;
		skeleton_dirty_list = skeleton;
	}
}
void MeshStorage::skeleton_allocate_data(RID p_skeleton, int p_bones, bool p_2d_skeleton) {
	Skeleton *skeleton = skeleton_owner.get_or_null(p_skeleton);
	ERR_FAIL_COND(!skeleton);
	ERR_FAIL_COND(p_bones < 0);
	if (skeleton->size == p_bones && skeleton->use_2d == p_2d_skeleton) {
		return;
	}
	skeleton->size = p_bones;
	skeleton->use_2d = p_2d_skeleton;
	skeleton->height = (p_bones * (p_2d_skeleton ? 2 : 3)) / 256;
	if ((p_bones * (p_2d_skeleton ? 2 : 3)) % 256) {