Lines Matching refs:shared_segment
41 zend_shared_segment_posix *shared_segment; in create_segments() local
77 shared_segment = (zend_shared_segment_posix *)((char *)(*shared_segments_p) + sizeof(void *)); in create_segments()
78 (*shared_segments_p)[0] = shared_segment; in create_segments()
83 …shared_segment->shm_fd = shm_create_largepage(shared_segment_name, shared_segment_flags, shared_s… in create_segments()
84 if (shared_segment->shm_fd != -1) { in create_segments()
90 shared_segment->shm_fd = shm_open(shared_segment_name, shared_segment_flags, shared_segment_mode); in create_segments()
91 if (shared_segment->shm_fd == -1) { in create_segments()
99 if (ftruncate(shared_segment->shm_fd, requested_size) != 0) { in create_segments()
105 …shared_segment->common.p = mmap(0, requested_size, PROT_READ | PROT_WRITE, MAP_SHARED, shared_segm… in create_segments()
106 if (shared_segment->common.p == MAP_FAILED) { in create_segments()
113 shared_segment->common.pos = 0; in create_segments()
114 shared_segment->common.size = requested_size; in create_segments()
119 static int detach_segment(zend_shared_segment_posix *shared_segment) in detach_segment() argument
121 munmap(shared_segment->common.p, shared_segment->common.size); in detach_segment()
122 close(shared_segment->shm_fd); in detach_segment()