Changeset 64765 in webkit


Ignore:
Timestamp:
Aug 5, 2010 11:03:02 AM (14 years ago)
Author:
andersca@apple.com
Message:

Add shared memory abstraction
https://bugs.webkit.org/show_bug.cgi?id=43535
<rdar://problem/8275295>

Reviewed by Adam Roben.

  • Platform/SharedMemory.h: Added.

(WebKit::SharedMemory::):
(WebKit::SharedMemory::size):
Return the size, in bytes, of the shared memory object.

(WebKit::SharedMemory::data):
Return a pointer to the shared memory object.

  • Platform/mac/SharedMemoryMac.cpp: Added.

(WebKit::SharedMemory::Handle):
A shared memory handle, which can be passed in a CoreIPC Connection.

(WebKit::SharedMemory::create):
Allocate the shared memory.

(WebKit::SharedMemory::~SharedMemory):
Deallocate the shared memory.

(WebKit::SharedMemory::createHandle):
Create a mach port and pass it to the handle.

(WebKit::SharedMemory::systemPageSize):
Return the system page size, in bytes.

  • Platform/win/SharedMemoryWin.cpp: Added.

Add stubbed out version.

  • WebKit2.xcodeproj/project.pbxproj:
  • win/WebKit2.vcproj:

Add files.

Location:
trunk/WebKit2
Files:
3 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit2/ChangeLog

    r64763 r64765  
     12010-08-04  Anders Carlsson  <andersca@apple.com>
     2
     3        Reviewed by Adam Roben.
     4
     5        Add shared memory abstraction
     6        https://bugs.webkit.org/show_bug.cgi?id=43535
     7        <rdar://problem/8275295>
     8
     9        * Platform/SharedMemory.h: Added.
     10        (WebKit::SharedMemory::):
     11        (WebKit::SharedMemory::size):
     12        Return the size, in bytes, of the shared memory object.
     13       
     14        (WebKit::SharedMemory::data):
     15        Return a pointer to the shared memory object.
     16       
     17        * Platform/mac/SharedMemoryMac.cpp: Added.
     18        (WebKit::SharedMemory::Handle):
     19        A shared memory handle, which can be passed in a CoreIPC Connection.
     20
     21        (WebKit::SharedMemory::create):
     22        Allocate the shared memory.
     23
     24        (WebKit::SharedMemory::~SharedMemory):
     25        Deallocate the shared memory.
     26
     27        (WebKit::SharedMemory::createHandle):
     28        Create a mach port and pass it to the handle.
     29
     30        (WebKit::SharedMemory::systemPageSize):
     31        Return the system page size, in bytes.
     32       
     33        * Platform/win/SharedMemoryWin.cpp: Added.
     34        Add stubbed out version.
     35
     36        * WebKit2.xcodeproj/project.pbxproj:
     37        * win/WebKit2.vcproj:
     38        Add files.
     39
    1402010-08-05  Jian Li  <jianli@chromium.org>
    241
  • trunk/WebKit2/WebKit2.xcodeproj/project.pbxproj

    r64688 r64765  
    4242                1A24B5F211F531E800C38269 /* MachUtilities.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A24B5F011F531E800C38269 /* MachUtilities.cpp */; };
    4343                1A24B5F311F531E800C38269 /* MachUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A24B5F111F531E800C38269 /* MachUtilities.h */; };
     44                1A24BED5120894D100FBB059 /* SharedMemory.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A24BED3120894D100FBB059 /* SharedMemory.h */; };
     45                1A24BF3A120896A600FBB059 /* SharedMemoryMac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A24BF39120896A600FBB059 /* SharedMemoryMac.cpp */; };
    4446                1A30066E1110F4F70031937C /* ResponsivenessTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A30066C1110F4F70031937C /* ResponsivenessTimer.h */; };
    4547                1A30EAC6115D7DA30053E937 /* ConnectionMac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A30EAC5115D7DA30053E937 /* ConnectionMac.cpp */; };
     
    346348                1A24B5F011F531E800C38269 /* MachUtilities.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MachUtilities.cpp; sourceTree = "<group>"; };
    347349                1A24B5F111F531E800C38269 /* MachUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MachUtilities.h; sourceTree = "<group>"; };
     350                1A24BED3120894D100FBB059 /* SharedMemory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SharedMemory.h; sourceTree = "<group>"; };
     351                1A24BF39120896A600FBB059 /* SharedMemoryMac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SharedMemoryMac.cpp; sourceTree = "<group>"; };
    348352                1A30066C1110F4F70031937C /* ResponsivenessTimer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ResponsivenessTimer.h; sourceTree = "<group>"; };
    349353                1A30EAC5115D7DA30053E937 /* ConnectionMac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ConnectionMac.cpp; sourceTree = "<group>"; };
     
    776780                                C0E3AA481209E45000A49D01 /* ModuleMac.mm */,
    777781                                BC0092F5115837A300E0AE2A /* RunLoopMac.mm */,
     782                                1A24BF39120896A600FBB059 /* SharedMemoryMac.cpp */,
    778783                                BC0092F6115837A300E0AE2A /* WorkQueueMac.cpp */,
    779784                        );
     
    11721177                                BC2E6E771141970C00A63B1E /* RunLoop.cpp */,
    11731178                                BC2E6E781141970C00A63B1E /* RunLoop.h */,
     1179                                1A24BED3120894D100FBB059 /* SharedMemory.h */,
    11741180                                BC2E6E7C1141970C00A63B1E /* WorkItem.h */,
    11751181                                BC2E6E7D1141970C00A63B1E /* WorkQueue.cpp */,
     
    13761382                                516A4A59120A1AB500C05B7F /* WKError.h in Headers */,
    13771383                                516A4A5D120A2CCD00C05B7F /* WebError.h in Headers */,
     1384                                1A24BED5120894D100FBB059 /* SharedMemory.h in Headers */,
    13781385                        );
    13791386                        runOnlyForDeploymentPostprocessing = 0;
     
    15831590                                C0E3AA7B1209E83500A49D01 /* Module.cpp in Sources */,
    15841591                                516A4A5A120A1AB500C05B7F /* WKError.cpp in Sources */,
     1592                                1A24BF3A120896A600FBB059 /* SharedMemoryMac.cpp in Sources */,
    15851593                        );
    15861594                        runOnlyForDeploymentPostprocessing = 0;
  • trunk/WebKit2/win/WebKit2.vcproj

    r64744 r64765  
    13621362                        </File>
    13631363                        <File
     1364                                RelativePath="..\Platform\SharedMemory.h"
     1365                                >
     1366                        </File>
     1367                        <File
    13641368                                RelativePath="..\Platform\WorkItem.h"
    13651369                                >
    13661370                        </File>
     1371            </File>
    13671372                        <File
    13681373                                RelativePath="..\Platform\WorkQueue.cpp"
     
    13821387                                <File
    13831388                                        RelativePath="..\Platform\win\RunLoopWin.cpp"
     1389                                        >
     1390                                </File>
     1391                                <File
     1392                                        RelativePath="..\Platform\win\SharedMemoryWin.cpp"
    13841393                                        >
    13851394                                </File>
Note: See TracChangeset for help on using the changeset viewer.