Search Results

Search found 259224 results on 10369 pages for 'hardware enablement stack'.

Page 6/10369 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • How to make Stack.Pop threadsafe

    - by user260197
    I am using the BlockingQueue code posted in this question, but realized I needed to use a Stack instead of a Queue given how my program runs. I converted it to use a Stack and renamed the class as needed. For performance I removed locking in Push, since my producer code is single threaded. My problem is how can thread working on the (now) thread safe Stack know when it is empty. Even if I add another thread safe wrapper around Count that locks on the underlying collection like Push and Pop do, I still run into the race condition that access Count and then Pop are not atomic. Possible solutions as I see them (which is preferred and am I missing any that would work better?): Consumer threads catch the InvalidOperationException thrown by Pop(). Pop() return a nullptr when _stack-Count == 0, however C++-CLI does not have the default() operator ala C#. Pop() returns a boolean and uses an output parameter to return the popped element. Here is the code I am using right now: generic <typename T> public ref class ThreadSafeStack { public: ThreadSafeStack() { _stack = gcnew Collections::Generic::Stack<T>(); } public: void Push(T element) { _stack->Push(element); } T Pop(void) { System::Threading::Monitor::Enter(_stack); try { return _stack->Pop(); } finally { System::Threading::Monitor::Exit(_stack); } } public: property int Count { int get(void) { System::Threading::Monitor::Enter(_stack); try { return _stack->Count; } finally { System::Threading::Monitor::Exit(_stack); } } } private: Collections::Generic::Stack<T> ^_stack; };

    Read the article

  • problem when trying to empty a stack in c

    - by frx08
    Hi all, (probably it's a stupid thing but) I have a problem with a stack implementation in C language, when I try to empty it, the function to empty the stack does an infinite loop.. the top of the stack is never null. where I commit an error? thanks bye! #include <stdio.h> #include <stdlib.h> typedef struct stack{ size_t a; struct stack *next; } stackPos; typedef stackPos *ptr; void push(ptr *top, size_t a){ ptr temp; temp = malloc(sizeof(stackPos)); temp->a = a; temp->next = *top; *top = temp; } void freeStack(ptr *top){ ptr temp = *top; while(*top!=NULL){ //the program does an infinite loop *top = temp->next; free(temp); } } int main(){ ptr top = NULL; push(&top, 4); push(&top, 8); //down here the problem freeStack(&top); return 0; }

    Read the article

  • Total stack sizes of threads in one process

    - by David
    I use pthreads_attr_getthreadsizes() to get default stack size of one thread, 8MB on my machine. But when I create 8 threads and allocate a very large stack size to them, say hundreds of MB, the program crash. So, I guess, shall ("Number of threads" x "stack size of per thread") shall less than a value(virtual memory size)?

    Read the article

  • Highlighting company name in Eclipse stack traces

    - by Robin Green
    Is there a way to make Eclipse highlight com.company (where for company substitute the name of the company you work for) in stack traces? It would make it fractionally easier and faster to home in on which parts of the stack trace were ours, and which were third-party code. I tried the logview plugin here, and while it does work, it makes the location information in the stack traces unclickable, which means I would waste more time than I would save.

    Read the article

  • Should a Stack have a maximum size?

    - by Sotirios Delimanolis
    I'm practicing my knowledge of ADTs by implementing some data structures, even if most already exist. With Stacks, a lot of books and other documentation I've read talk about the stack throwing an error when you try to add an element but the stack is full. In a java implementation (or any other), should I specifically keep track of a maximum stack size (from constructor), check to see if that size is reached, and throw an overflow exception if it is? Or is not such a big deal?

    Read the article

  • Add every value in stack

    - by rezivor
    I am trying to figure out a method that will add every value in a stack. The goal is to use that value to determine if all the values in the stack are even. I have written to code to do this template <class Object> bool Stack<Object>::objectIsEven( Object value ) const { bool answer = false; if (value % 2 == 0) answer = true; return( answer ); } However, I am stumped on how to add all of the stack's values in a separate method

    Read the article

  • Hardware upgrade: Windows 7 bluescreens, Vista loads

    - by Daniel Schaffer
    I just did a fairly significant hardware upgrade while keeping my hard disks. The old system was a dell Optiplex 745 with an Intel Core 2 duo, LGA 775. The new system is custom built, Intel i5 750. I know you're supposed to do a clean install with a hardware upgrade like this, but I'd had success in the past doing the stealth hardware upgrade like this, so I figured I'd give it a shot. Windows 7 Ultimate 64 bit gets through the loading screen and immediately blue screens and reboots. Windows Vista Home Premium 32-bit, which I have on an old hard drive from an AMD box (!!) loads up fine. I ran through the windows memory checker just to be sure, and my memory is fine. So, is the BSOD the result of some sort of protection mechanism specific to Windows 7? Is there any hope of salvaging that install?

    Read the article

  • Is there a way to disable the hardware on/off switch for the Wireless interface?

    - by avee
    I have an HP 520 and is running the latest Ubuntu 11.10. The hardware works fine with Ubuntu with one exception: The device has a hardware switch for turning the wifi on and off. Every time the wi-fi is disabled through the hardware switch, I am unable to bring it on again. The message on the networking popup would be device not ready. What I am looking for is a way to disable the hardware switch altogether so that when users accidentally press the button, the wifi would not be disabled. There is no setting to disable the switch in the BIOS. Hardware info from lspci -nn: 00:00.0 Host bridge [0600]: Intel Corporation Mobile 945GME Express Memory Controller Hub [8086:27ac] (rev 03) 00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GME Express Integrated Graphics Controller [8086:27ae] (rev 03) 00:02.1 Display controller [0380]: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller [8086:27a6] (rev 03) 00:1b.0 Audio device [0403]: Intel Corporation N10/ICH 7 Family High Definition Audio Controller [8086:27d8] (rev 01) 00:1c.0 PCI bridge [0604]: Intel Corporation N10/ICH 7 Family PCI Express Port 1 [8086:27d0] (rev 01) 00:1c.1 PCI bridge [0604]: Intel Corporation N10/ICH 7 Family PCI Express Port 2 [8086:27d2] (rev 01) 00:1d.0 USB Controller [0c03]: Intel Corporation N10/ICH 7 Family USB UHCI Controller #1 [8086:27c8] (rev 01) 00:1d.7 USB Controller [0c03]: Intel Corporation N10/ICH 7 Family USB2 EHCI Controller [8086:27cc] (rev 01) 00:1e.0 PCI bridge [0604]: Intel Corporation 82801 Mobile PCI Bridge [8086:2448] (rev e1) 00:1f.0 ISA bridge [0601]: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge [8086:27b9] (rev 01) 00:1f.2 IDE interface [0101]: Intel Corporation 82801GBM/GHM (ICH7 Family) SATA IDE Controller [8086:27c4] (rev 01) 02:06.0 CardBus bridge [0607]: ENE Technology Inc CB1410 Cardbus Controller [1524:1410] (rev 01) 02:08.0 Ethernet controller [0200]: Intel Corporation 82562ET/EZ/GT/GZ - PRO/100 VE (LOM) Ethernet Controller Mobile [8086:1068] (rev 01) 10:00.0 Network controller [0280]: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection [8086:4222] (rev 02) The output from lsmod | grep iwl: iwl3945 73329 0 iwl_legacy 71499 1 iwl3945 mac80211 272785 2 iwl3945,iwl_legacy cfg80211 172392 3 iwl3945,iwl_legacy,mac80211

    Read the article

  • 'Memory read error',Sever hardware error?

    - by wss8848
    hello I got a error about my server which is running CentOS5.5. MCE 20 HARDWARE ERROR. This is *NOT* a software problem! Please contact your hardware vendor CPU 1 BANK 8 TSC 6ab9ff9745f62 [at 2394 Mhz 9 days 1:50:52 uptime (unreliable)] MISC cf36ad0100081186 ADDR 203376500 MCG status: MCi status: MCi_MISC register valid MCi_ADDR register valid MCA: MEMORY CONTROLLER RD_CHANNELunspecified_ERR Transaction: Memory read error STATUS 8c0000400001009f MCGSTATUS 0 what is the matter? is memory card error or memory controller error?

    Read the article

  • Why does hardware get slower with time?

    - by Alexey Kulikov
    Why does hardware get slower with time? I have been a PC owner since 1990 and every computer I have had in my life became really, really slow after 3-4 years (even with a full system-reinstall). It is the case with Windows PCs. It is also the case with Apple Hardware. Why is this happening? Can this be avoided?

    Read the article

  • Ubuntu hardware compatability

    - by CT
    I have only previously played with ubuntu using virtual machines with VMware Fusion. So everything just sort of worked. I've never had to install any drivers. I'm considering putting it on some real hardware and using it as a media center. What should I be looking for as far as checking hardware compatibility? How does installing drivers work? Any quick and easy recommendations / guides?

    Read the article

  • C++, using stack.h read a string, then display it in reverse

    - by user1675108
    For my current assignment, I have to use the following header file, #ifndef STACK_H #define STACK_H template <class T, int n> class STACK { private: T a[n]; int counter; public: void MakeStack() { counter = 0; } bool FullStack() { return (counter == n) ? true : false ; } bool EmptyStack() { return (counter == 0) ? true : false ; } void PushStack(T x) { a[counter] = x; counter++; } T PopStack() { counter--; return a[counter]; } }; #endif To write a program that will take a sentence, store it into the "stack", and then display it in reverse, and I have to allow the user to repeat this process as much as they want. The thing is, I am NOT allowed to use arrays (otherwise I wouldn't need help with this), and am finding myself stumped. To give an idea of what I am attempting, here is my code as of posting, which obviously does not work fully but is simply meant to give an idea of the assignment. #include <iostream> #include <cstring> #include <ctime> #include "STACK.h" using namespace std; int main(void) { auto time_t a; auto STACK<char, 256> s; auto string curStr; auto int i; // Displays the current time and date time(&a); cout << "Today is " << ctime(&a) << endl; s.MakeStack(); cin >> curStr; i = 0; do { s.PushStack(curStr[i]); i++; } while (s.FullStack() == false); do { cout << s.PopStack(); } while (s.EmptyStack() == false); return 0; } // end of "main" **UPDATE This is my code currently #include <iostream> #include <string> #include <ctime> #include "STACK.h" using namespace std; time_t a; STACK<char, 256> s; string curStr; int i; int n; // Displays the current time and date time(&a); cout << "Today is " << ctime(&a) << endl; s.MakeStack(); getline(cin, curStr); i = 0; n = curStr.size(); do { s.PushStack(curStr[i++]); i++; }while(i < n); do { cout << s.PopStack(); }while( !(s.EmptyStack()) ); return 0;

    Read the article

  • Disable Java Hardware Acceleration in windows?

    - by Odys
    I have some issues with my graphics card and I want to disable Hardware Acceleration for java apps. Everything that uses HA is displayed blurry. I've seen some tutorials on how to set this parameter -Dsun.java2d.d3d=false The problem is that the Java Control panel itself is using hardware acceleration and I cannot see anything in order to add this parameter. Edit: Went to java control panel in safe mode, added that parameter and problem continues.. Edit2: Win 7 x64 JRE 6 update 30 Edit3: my deployment.properties (after your suggestions) file is: #deployment.properties #Sun Jan 08 01:12:04 EET 2012 deployment.version=6.0 deployment.capture.mime.types=true deployment.browser.path=C\:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe #Java Deployment jre's #Sun Jan 08 01:12:04 EET 2012 deployment.javaws.jre.0.registered=true deployment.javaws.jre.0.platform=1.6 deployment.javaws.jre.0.osname=Windows deployment.javaws.jre.0.path=C\:\\Program Files (x86)\\Java\\jre6\\bin\\javaw.exe deployment.javaws.jre.0.product=1.6.0_30 deployment.javaws.jre.0.osarch=x86 deployment.javaws.jre.0.location=http\://java.sun.com/products/autodl/j2se deployment.javaws.jre.0.enabled=true deployment.javaws.jre.0.args=-Dsun.java2d.d3d\=false deployment.javaws.jre.1.args=-Dsun.java2d.d3d\=false deployment.javaws.jre.0.args=-Dsun.java2d.noddraw=true deployment.javaws.jre.1.args=-Dsun.java2d.noddraw=true still hardware acceleration is enabled. Is there a possibility that applications can override these settings?

    Read the article

  • Hardware reserved memory issue

    - by Robert Koritnik
    I've seen lots of folks having problem with hardware reserved memory issue in Windows 7/Server 2008 R2. I have it myself but not as huge as others have. Problem description When you install Windows 7 (or its bigger brother Windows Server 2008 R2) your memory may not be fully utilised. If you look at Task Manager > Performance Tab > Resource Monitor > Memory Tab And scroll to the bottom of the list you will see a graphical representation of your memory. Some of it may be hardware reserved. Previous Windows versions didn't have this problem. System was able to utilise all memory available. Question Is there any solution to lower/remove hardware reserved memory? Sidenote I tried installing 32 and 64 bit versions but to no avail. I also tried both Windows: 7 and Server 2008 R2. But always get the same amount reserved by HW. On previous Windows versions I had more memory available because I'm simultaneously running 2 VMs on host (so three machines all together). And my memory peaks much higher now as it did on older versions.

    Read the article

  • Hardware Requirements & Tuning - Flash Media Server 3.5 Interactive

    - by Anthony Kanago
    I am trying to spec out a server to purchase (physically, not rented from someone like softlayer.com) to run an intranet instace of Flash Media Server 3.5 Interactive. In general, the server will likely be fielding somewhere on the order of 400 connections at a time at the upper limit. Of course, should this increase, we don't want to be stuck. While the decision is not final, we will likely be running the server on Red Hat rather than Windows. The server will be run on gigabit ethernet. I have two related questions: What sort of hardware would I need realistically to support this? What advice can you offer for settings in tuning FMS/the OS to be performant to this level? We are looking for a bare minimum that will run this effectively to save on costs. Realistically, the average number of connections will be fairly low (50-150) by comparison with that upper limit estimate. To reiterate: we just want to be cautious in not getting caught when we need more power, but we also need a low-cost solution (doesn't everyone?) and that may take priority. Windows and RedHat are the two officially supported operating systems. Since FMS is stated to be 32-bit only, I'm sticking with a 32-bit OS. The hardware requirements listed by Adobe on their website are: 3.2GHz Intel® Pentium® 4 processor (dual Intel Xeon® or faster recommended) 2GB of RAM (4GB recommended) 1Gb Ethernet card So what realistically do I need for those sorts of connection numbers, and what can I due to tune things up to get more out of less hardware? Thanks!

    Read the article

  • Linux - real-world hardware RAID controller tuning (scsi and cciss)

    - by ewwhite
    Most of the Linux systems I manage feature hardware RAID controllers (mostly HP Smart Array). They're all running RHEL or CentOS. I'm looking for real-world tunables to help optimize performance for setups that incorporate hardware RAID controllers with SAS disks (Smart Array, Perc, LSI, etc.) and battery-backed or flash-backed cache. Assume RAID 1+0 and multiple spindles (4+ disks). I spend a considerable amount of time tuning Linux network settings for low-latency and financial trading applications. But many of those options are well-documented (changing send/receive buffers, modifying TCP window settings, etc.). What are engineers doing on the storage side? Historically, I've made changes to the I/O scheduling elevator, recently opting for the deadline and noop schedulers to improve performance within my applications. As RHEL versions have progressed, I've also noticed that the compiled-in defaults for SCSI and CCISS block devices have changed as well. This has had an impact on the recommended storage subsystem settings over time. However, it's been awhile since I've seen any clear recommendations. And I know that the OS defaults aren't optimal. For example, it seems that the default read-ahead buffer of 128kb is extremely small for a deployment on server-class hardware. The following articles explore the performance impact of changing read-ahead cache and nr_requests values on the block queues. http://zackreed.me/articles/54-hp-smart-array-p410-controller-tuning http://www.overclock.net/t/515068/tuning-a-hp-smart-array-p400-with-linux-why-tuning-really-matters http://yoshinorimatsunobu.blogspot.com/2009/04/linux-io-scheduler-queue-size-and.html For example, these are suggested changes for an HP Smart Array RAID controller: echo "noop" > /sys/block/cciss\!c0d0/queue/scheduler blockdev --setra 65536 /dev/cciss/c0d0 echo 512 > /sys/block/cciss\!c0d0/queue/nr_requests echo 2048 > /sys/block/cciss\!c0d0/queue/read_ahead_kb What else can be reliably tuned to improve storage performance? I'm specifically looking for sysctl and sysfs options in production scenarios.

    Read the article

  • Stack overflow in xp cmd console

    - by Dave
    I am using an older program whose source code I cannot see. I am using the cmd.exe console in windows xp. The program ran with no problems on an xp machine last year, while a stack overflow code 2000 error was observed on a different xp machine (easy fix - use the machine that works). I tried running the program on the previously working machine lately, and now am getting the same error. No changes to the os were made and I did not change the service pack version. Any ideas on how to get around this stack overflow error so I can use the program? Dosbox will at least open the program, however it does not run to completion. Thanks!

    Read the article

  • please assist me debug a stack trace

    - by Eds
    I am having an issue on a windows 2003 terminal server, where the system process is using a constantly high amount of CPU. I believe that it is the srv.sys that is causing an issue, but not quite sure how to fully diagnose the problem. I have looked at the stack for the srv.sys!workerthread, which is what seems to be using the CPU. The stack is as follows: 0 ntoskrnl.exe!KeSetBasePriorityThread+0xf7 1 ntoskrnl.exe!MiDeleteAddressesInWorkingSet+0x103 2 srv.sys!WorkerThread+0x7c 3 ntoskrnl.exe!FsRtNotifyFilterReportChange+0x10 4 ntoskrnl.exe!RtClearBits+0x24 Can anyone offer any advice based on the above, or some other things I could look at in order to get to the bottom of this? Many Thanks, Eds

    Read the article

  • Enablement 2.0 Get Specialized!

    - by michaela.seika(at)oracle.com
      Check the new OPN Certified Specialist Exam Study Guides – your quick reference to the training options to guide partners pass OPN Specialist Exams! What are the advantages of the Exam Study Guides? Cover the Implementation Specialist Exams that count towards OPN Specialization program. Capture Exam Topics, Exam Objectives and Training Options. Define the Exam Objectives by learner or practitioner level of knowledge: Learner-level: questions require the candidate to recall information to derive the correct answer Practitioner-level: questions require the candidate to derive the correct answer from an application of their knowledge. Map by each Exam Topic the alternative training options that are available at Oracle. Where to find the Exam Study Guides? On Enablement 2.0 > Spotlight On each Knowledge Zone > Implement On each Specialist Implementation Guided Learning Path For More Information Oracle Certification Program Beta Exams OPN Certified Specialist Exams OPN Certified Specialist FAQ Contact Us Please direct any inquiries you may have to Oracle Partner Enablement team at [email protected].

    Read the article

  • Enablement 2.0 Get Specialized!

    - by mseika
    Enablement 2.0 Get Specialized! Oracle PartnerNetwork Specialized program is releasing new certifications on our latest products, and partners are invited to be the first candidates. Oracle Taleo Enterprise Cloud Service 2012 Specialization · New Specialist Guided Learning Paths Available! · Oracle Taleo Cloud Service 2012 Sales Specialist · Oracle Taleo Cloud Service 2012 PreSales Specialist · Oracle Taleo Cloud Service 2012 Support Specialist · New Specialist Assessments Available! · Oracle Taleo Cloud Service 2012 Sales Specialist Assessment · Oracle Taleo Cloud Service 2012 PreSales Specialist Assessment · Oracle Taleo Cloud Service 2012 Support Specialist Assessment · Coming Soon! - New Certified Implementation Specialist Exam! · Oracle Taleo Cloud Service 2012 Recruiting Certified Implementation Specialist Contact UsPlease direct any inquiries you may have to Oracle Partner Enablement team [email protected].

    Read the article

  • Enablement 2.0 Get Specialized!

    - by mseika
    Enablement 2.0 Get Specialized! Oracle PartnerNetwork Specialized program is releasing new certifications on our latest products, and partners are invited to be the first candidates. Oracle Taleo Enterprise Cloud Service 2012 Specialization · New Specialist Guided Learning Paths Available! · Oracle Taleo Cloud Service 2012 Sales Specialist · Oracle Taleo Cloud Service 2012 PreSales Specialist · Oracle Taleo Cloud Service 2012 Support Specialist · New Specialist Assessments Available! · Oracle Taleo Cloud Service 2012 Sales Specialist Assessment · Oracle Taleo Cloud Service 2012 PreSales Specialist Assessment · Oracle Taleo Cloud Service 2012 Support Specialist Assessment · Coming Soon! - New Certified Implementation Specialist Exam! · Oracle Taleo Cloud Service 2012 Recruiting Certified Implementation Specialist Contact UsPlease direct any inquiries you may have to Oracle Partner Enablement team [email protected].

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >