summaryrefslogtreecommitdiff
path: root/deps/v8/src/platform-win32.cc
diff options
context:
space:
mode:
authorRyan Dahl <ry@tinyclouds.org>2009-11-18 15:25:58 +0100
committerRyan Dahl <ry@tinyclouds.org>2009-11-18 15:28:54 +0100
commit728d8a37f471afaeaa6af19823f9da8c41f1f65a (patch)
tree21e014089ff0bfb7d493691620ab9eee51176d28 /deps/v8/src/platform-win32.cc
parent8195e0f7232fed3d6a3a2cc8464fec5e36f4433c (diff)
downloadnode-new-728d8a37f471afaeaa6af19823f9da8c41f1f65a.tar.gz
Upgrade v8 to 2.0
(With just one change: remove -Werror)
Diffstat (limited to 'deps/v8/src/platform-win32.cc')
-rw-r--r--deps/v8/src/platform-win32.cc15
1 files changed, 11 insertions, 4 deletions
diff --git a/deps/v8/src/platform-win32.cc b/deps/v8/src/platform-win32.cc
index d1f53194fb..1be4b77f8a 100644
--- a/deps/v8/src/platform-win32.cc
+++ b/deps/v8/src/platform-win32.cc
@@ -839,7 +839,7 @@ void* OS::Allocate(const size_t requested,
size_t* allocated,
bool is_executable) {
// VirtualAlloc rounds allocated size to page size automatically.
- size_t msize = RoundUp(requested, GetPageSize());
+ size_t msize = RoundUp(requested, static_cast<int>(GetPageSize()));
// Windows XP SP2 allows Data Excution Prevention (DEP).
int prot = is_executable ? PAGE_EXECUTE_READWRITE : PAGE_READWRITE;
@@ -852,7 +852,7 @@ void* OS::Allocate(const size_t requested,
ASSERT(IsAligned(reinterpret_cast<size_t>(mbase), OS::AllocateAlignment()));
*allocated = msize;
- UpdateAllocatedSpaceLimits(mbase, msize);
+ UpdateAllocatedSpaceLimits(mbase, static_cast<int>(msize));
return mbase;
}
@@ -1316,6 +1316,11 @@ int OS::StackWalk(Vector<OS::StackFrame> frames) { return 0; }
#endif // __MINGW32__
+uint64_t OS::CpuFeaturesImpliedByPlatform() {
+ return 0; // Windows runs on anything.
+}
+
+
double OS::nan_value() {
#ifdef _MSC_VER
// Positive Quiet NaN with no payload (aka. Indeterminate) has all bits
@@ -1361,7 +1366,7 @@ bool VirtualMemory::Commit(void* address, size_t size, bool is_executable) {
return false;
}
- UpdateAllocatedSpaceLimits(address, size);
+ UpdateAllocatedSpaceLimits(address, static_cast<int>(size));
return true;
}
@@ -1689,7 +1694,9 @@ bool Win32Socket::Connect(const char* host, const char* port) {
}
// Connect.
- status = connect(socket_, result->ai_addr, result->ai_addrlen);
+ status = connect(socket_,
+ result->ai_addr,
+ static_cast<int>(result->ai_addrlen));
freeaddrinfo(result);
return status == 0;
}