Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 20,944
» Latest member: NeroSx
» Forum threads: 21,954
» Forum posts: 22,921

Full Statistics

Online Users
There are currently 2680 online users.
» 0 Member(s) | 2675 Guest(s)
Applebot, Baidu, Bing, Facebook, Google

Latest Threads
How to play Squirrel Girl...
Forum: PC Discussion
Last Post: xSicKxBot

» Replies: 0
» Views: 10
[WoW Retail News] Paladin...
Forum: World of Warcraft
Last Post: xSicKxBot

» Replies: 0
» Views: 10
[Steam Release] Rec Room
Forum: New Game Releases
Last Post: xSicKxBot

» Replies: 0
» Views: 15
[DevBlog MS] Share your ....
Forum: C#, Visual Basic, & .Net Frameworks
Last Post: xSicKxBot

» Replies: 0
» Views: 16
[Steam Release] Clone Dro...
Forum: New Game Releases
Last Post: xSicKxBot

» Replies: 0
» Views: 18
[WoW Retail News] Noctina...
Forum: World of Warcraft
Last Post: xSicKxBot

» Replies: 0
» Views: 21
[DevBlog MS] Use C# union...
Forum: C#, Visual Basic, & .Net Frameworks
Last Post: xSicKxBot

» Replies: 0
» Views: 21
How to get Santa Shaq ski...
Forum: PC Discussion
Last Post: xSicKxBot

» Replies: 0
» Views: 27
[Steam Release] Totally A...
Forum: New Game Releases
Last Post: xSicKxBot

» Replies: 0
» Views: 22
[DevBlog MS] Announcing ....
Forum: C#, Visual Basic, & .Net Frameworks
Last Post: xSicKxBot

» Replies: 0
» Views: 28

 
  PS4 - The Crew 2
Posted by: xSicKxBot - 06-29-2018, 12:34 PM - Forum: New Game Releases - No Replies

The Crew 2



The newest iteration in the franchise, The Crew 2 captures the thrill of the American motorsports spirit in an open world. Welcome to Motornation, a huge, varied, action-packed playground built for motorsports throughout the entire US of A. Enjoy unrestrained exploration on ground, sea, and sky. From coast to coast, street and pro racers, off-road explorers, and freestylers gather and compete in all kinds of disciplines. Join them in high-octane contests and share every glorious moment with the world. The Crew 2 gives you the chance to showcase your skills and rise as a multi-skilled motorsports champion. [Ubisoft]

Publisher: Ubisoft

Release Date: Jun 26, 2018

Print this item

  XONE - NieR: Automata - Become as Gods Edition
Posted by: xSicKxBot - 06-29-2018, 11:41 AM - Forum: New Game Releases - No Replies

NieR: Automata - Become as Gods Edition



NieR: Automata is an action RPG set in a post-apocalyptic world overrun by machine lifeforms and abandoned by mankind. As part of an android army created by humans to reclaim the planet, players will fight their way through the mechanical horde using a collective of close-combat weapons and ranged attacks.

Publisher: Square Enix

Release Date: Jun 26, 2018

Print this item

  News - Steam Intergalactic Summer Sale Day 7
Posted by: xSicKxBot - 06-29-2018, 11:41 AM - Forum: Lounge - No Replies

Steam Intergalactic Summer Sale Day 7

The Steam Intergalactic Summer Sale continues! For the next eight days, take advantage of huge savings throughout our store on over ten thousand games. You can also help unlock free games by playing our Summer Saliens Game.

Today’s Featured Deals include:

Assassin’s Creed Franchise – Up to 66% off
They Are Billions – 20% off
Hollow Knight – 34% off
Euro Truck Simulator 2 – 75% off
Counter-Strike: Global Offensive – 50% off
Romance of the Three Kingdoms XIII – 40% off
Watch_Dogs Franchise – 67% off
Age of Wonders Franchise – Up to 75% off
and many more

Along with the sale is the Summer Saliens Game. Team up with other Saliens to fight The Duldrumz on different planets and free the abducted games. Gain XP as you battle, level up, unlock new abilities, and win cosmetic items to deck out your Salien. Plus, get Summer Sale Trading Cards just for playing.

Choose to battle on a planet that piques your interest and you’ll automatically be entered for a chance to win one of its rewards when it’s conquered. The longer your Salien spends on a planet the higher your chances of winning! The groups with the most tiles when a planet is taken will get to plant their flag as conquerors, undoubtedly gaining Saliverse-wide fame in the process.

The Steam Intergalactic Summer Sale will run until 10 AM Pacific, July 5th. Complete information can be found HERE.

Print this item

  News - Report: Snap looking to launch a game platform for Snapchat
Posted by: xSicKxBot - 06-29-2018, 11:41 AM - Forum: Lounge - No Replies

Report: Snap looking to launch a game platform for Snapchat

Snap is reportedly looking to bolster the offerings of its messaging app Snapchat by introducing a full-fledged video game platform to the mobile chat app. 

While Snap itself declined to comment on the rumor, sources speaking to The Information say the coming platform will allow game developers to create games that can be played within Snapchat. Other platforms like Facebook Messenger have introduced in-app, social games to their chat tools in the past, so Snapchat’s rumored change isn’t that far fetched. 

The company notably already offers some augmented reality games, dubbed Snappables, that are housed alongside other Snapchat lenses in the app and can be controlled with touch, motion, or facial expressions. 

However, those Snappables are created internally by Snap. This time around, Snapchat’s rumored game platform, at least according to one of The Information’s sources, will allow external developers to create Snapchat games. That source notes that the company has reportedly already brought one unnamed game publisher on board for the project as well. 

Print this item

  Steam - Steam Intergalactic Summer Sale Day 4
Posted by: xSicKxBot - 06-29-2018, 11:41 AM - Forum: PC Discussion - No Replies

Steam Intergalactic Summer Sale Day 4

The Steam Intergalactic Summer Sale continues! For the next eleven days, take advantage of huge savings throughout our store on over ten thousand games. You can also help unlock free games by playing our Summer Saliens Game.

Today’s Featured Deals include:

The Elder Scrolls Franchise – Up to 50% off
Tomb Raider Franchise – Up to 89% off
Battletech – 20% off
The Long Dark – 75% off
Star Trek: Bridge Crew – 50% off
Sid Meier’s Civilization Franchise – Up to 75% off
Mad Max – 75% off
Portal 2 – 90% off
and many more

Along with the sale is the Summer Saliens Game. Team up with other Saliens to fight The Duldrumz on different planets and free the abducted games. Gain XP as you battle, level up, unlock new abilities, and win cosmetic items to deck out your Salien. Plus, get Summer Sale Trading Cards just for playing.

Choose to battle on a planet that piques your interest and you’ll automatically be entered for a chance to win one of its rewards when it’s conquered. The longer your Salien spends on a planet the higher your chances of winning! The groups with the most tiles when a planet is taken will get to plant their flag as conquerors, undoubtedly gaining Saliverse-wide fame in the process.

The Steam Intergalactic Summer Sale will run until 10 AM Pacific, July 5th. Complete information can be found HERE.

Print this item

  Hyperledger’s Brian Behlendorf Named as Top Blockchain Influencer by New York Times
Posted by: xSicKxBot - 06-29-2018, 09:06 AM - Forum: Linux, FreeBSD, and Unix types - No Replies

Hyperledger’s Brian Behlendorf Named as Top Blockchain Influencer by New York Times

Brian Behlendorf, Executive Director of the Linux Foundation’s Hyperledger project, has been named one of the top 10 influential voices in the blockchain world, in a New York Times commentary titled “The People Leading the Blockchain Revolution.” Blockchain technology—which encompasses smart contracts, distributed ledgers, and more—is already transforming contracts, payment processing, asset protection, and supply chain management.

In the article, Behlendorf is credited with driving the evolution and widespread adoption of numerous essential blockchain platforms and tools.

“Mr. Behlendorf has helped bring in other big names who are helping to make Hyperledger the focus of much of the corporate and governmental interest in blockchains today,” the Times reports.

Read more at The Linux Foundation

Print this item

  News - Fortnite Shopping Carts Are Back In Time For Week 9 Challenges
Posted by: xSicKxBot - 06-29-2018, 06:35 AM - Forum: Lounge - No Replies

Fortnite Shopping Carts Are Back In Time For Week 9 Challenges

It's not uncommon for Fortnite items to be added and removed, but the game's first vehicles--shopping carts--have been in and out an inordinate amount. Issues with the shopping cart saw the vehicle removed once again recently, but Epic has announced it has been re-enabled in Battle Royale across all platforms: PC, PS4, Xbox One, Nintendo Switch, and mobile. [Update: It turns out the timing for the returning of shopping carts is quite fortunate, as Week 9 challenges task players with using one.]

Epic shared the news on Fortnite's Twitter account, though that's inevitably led to quips from players asking how long this will be the case for. This most recent period saw it disabled for almost a full week, and this is just one of multiple instances where Epic has temporarily pulled the vehicle from the game.

Being Fortnite's first vehicle, it seems as if its introduction has been a learning process for Epic. Players have been able to use the shopping cart to reach areas they should not be able to (specifically, underneath the map), which is problematic for a competitive PvP game.

The shopping cart can be used solo; it also allows for one player to push around another who sits in the basket (where they can fire a weapon). It might not be the best way to win a match--though the meta around that may be changing--but it is a hell of a lot of fun.

Fortnite's most recent update introduced the Stink Bomb, a new type of grenade that deals damage over time in an area. Meanwhile, the current season is nearly set to conclude, but there's still time to complete Season 4 challenges.

Print this item

  Microsoft - SHOWTIME, Amblin Television and 343 Industries bring Halo to television
Posted by: xSicKxBot - 06-29-2018, 06:35 AM - Forum: Windows - No Replies

SHOWTIME, Amblin Television and 343 Industries bring Halo to television

It’s a big day for Halo – today, SHOWTIME president and CEO David Nevins announced the network has ordered a 10-episode season based on the legendary video game franchise!

In its adaptation for SHOWTIME, Halo (working title) will take place in the universe that first came to be in 2001, dramatizing an epic 26th-century conflict between humanity and an alien threat known as the Covenant. Kyle Killen (Awake) will serve as executive producer, writer and showrunner. Rupert Wyatt (Rise of the Planet of the Apes) will direct multiple episodes and also executive produce the hour-long series which enters production in early 2019.

Halo is our most ambitious series ever, and we expect audiences who have been anticipating it for years to be thoroughly rewarded,” said Nevins. “In the history of television, there simply has never been enough great science fiction. Kyle Killen’s scripts are thrilling, expansive and provocative, Rupert Wyatt is a wonderful, world-building director, and their vision of Halo will enthrall fans of the game while also drawing the uninitiated into a world of complex characters that populate this unique universe.”

“This is a truly exciting moment for the Halo franchise,” stated Kiki Wolfkill, head of Halo Transmedia at 343 Industries. “Together with our creative and production partners at SHOWTIME and Amblin Television, the Halo television series will represent new and exciting way for fans to enter and engage with the Halo universe. We can’t wait to share more on what’s ahead.”

Halo will be executive produced by Killen, Wyatt and Scott Pennington, along with Justin Falvey and Darryl Frank for Amblin Television. The series will be distributed globally by CBS Studios International.

For all things Halo and the recently announced Halo Infinite, be sure to check out Halo Waypoint and stay tuned to Xbox Wire.

Print this item

  Van Jones & Linus Torvalds to Keynote at Open Source Summit North America
Posted by: xSicKxBot - 06-29-2018, 02:20 AM - Forum: Linux, FreeBSD, and Unix types - No Replies

Van Jones & Linus Torvalds to Keynote at Open Source Summit North America

We’ve announced additional keynotes at Open Source Summit North America, including:

  • Van Jones, President & Founder of the nonprofit, Dream CorpsCNN ContributorBest-Selling Author; Human Rights, Education and Clean Energy Advocate
  • Austen Collins, Founder & CEOServerless Inc.
  • Linus Torvalds, creator of Linux and Git, in conversation with Dirk Hohndel, VP & Chief Open Source Officer, VMware

View the Full Schedule >>

The event also features the Open Collaboration Conference where ecosystem leaders learn to navigate open source transformation with sessions covering compliance, community leadership and open source program office management in the new TODO track. The Diversity Empowerment Summit is also featured, which highlights the ways in which the community can benefit from expanding diversity and inclusion practices.

Register now to save $150 through July 21.

Register Now >>

Read more at The Linux Foundation

Print this item

  Stack vs Heap. What’s the Difference and Why Should I Care?
Posted by: xSicKxBot - 06-28-2018, 07:27 PM - Forum: Linux, FreeBSD, and Unix types - No Replies

Stack vs Heap. What’s the Difference and Why Should I Care?

I’m four months into the curriculum at Holberton School and we’ve solved multiple problems using the malloc, realloc, calloc and free functions in the C programming language. What better way to build a solid foundation of how memory gets allocated then to write a technical post on the stack versus the heap?

This article explains in depth:


What are the five segments of memory?

What is the stack?

What is the heap?

How does understanding the two make you a better software engineer?

What are the five segments of memory?


When we write applications, files, or any logic that is typed in an editor and executed on the computer, the computer has to allocate memory for the program to run. The memory that is assigned to a program or application in a computer can be divided into five parts. The amount of memory that get’s assigned to an application depends on the computer’s architecture and will vary across most devices, but the variable that remains constant is the five parts of an application’s memory which are the heap, stack, initialized data segment, uninitialized data segment, and the text segment.

The initialized data segmentconsists of all the global and static variables that are initialized when a file gets compiled. The uninitialized data segment consists of all global and static variables that are initialized to zero or do not have explicit initialization in source code.

At Holberton, most of the time we are not concerned about the uninitialized data segment because when we compile our programs with gcc, we use the flags, -Wall -Wextra -pedantic -Werror and we use an internal stylistic checker called betty which treats warning as errors when uninitialized variables are present. Having unused variables in our programs gets flagged and is not a best practice. The text segment, also known as the code segment, contains the machine instructions which make up your program. The text segment is often read-only and prevents a program from accidentally modifying its instructions.

What is the stack?


The stack is a segment of memory where data like your local variables and function calls get added and/or removed in a last-in-first-out (LIFO) manner. When you compile a program, the compiler enters through the main function and a stack frame is created on the stack. A frame, also known as an activation record is the collection of all data on the stack associated with one subprogram call. The main function and all the local variables are stored in an initial frame.

Program vs Stack usage

In the picture above, we have one stack frame on the stack that holds the main function, along with the local a, b and sum variables. After using the printf() function the frame we created along with the local variables are only accessible in memory for the duration of the frame are no longer accessible after returning the 0 value from the function.

What happens with the stack when we call multiple functions? To illustrate the stack in it’s LIFO manner, let’s solve a problem using recursion. When we call multiple functions in our application, we use multiple stack frames in a last-in-first-out approach meaning that the last stack frame we’ve created on the stack is the first stack that will be released after the function is done executing its logic. Let’s go over an example of printing out the name “Holberton” recursively and show how our code affects the stack memory segment.

Yes, I have a whiteboard on the back of my door at my house.

When we compile our code using gcc _putchar.c 0-puts_recursion.c 0-main.c , the compiler enters our program through int main(void) and creates a frame with the function int main(void) and _puts_recursion("Holberton") living on that frame as illustrated on the image above. When the compiler runs into the _puts_recursion() function, it calls that function and creates another stack frame on top of the previous stack frame where int main(void) lives. We are now in our second stack frame in our program and have entered in the _puts_recursion(char *s)function where *s is equal to 'H' and is only accessible in that stack frame. Because 'H' does not equal '\0' , we will continue with our function calls and execute the _putchar('H') function and enter into the same function _puts_recursion(++s). The argument ++s moves the memory address of the *s one byte because the size of a char is 1 byte on our machine, and now _puts_recursion is calling the function as _puts_recrusion('o') . Each time the _puts_recursion function is called, a new stack frame is put on the stack until we hit the terminating condition which is if (*s == '\0').

Every time a new stack frame is created, the stack pointer moves with it until it reaches the terminating condition. A stack pointer is a small register that stores the address of the last program request in a frame. When we hit the terminating condition, we execute our logic, then start to unwind the stack or pop off stack frames in the last-in-first-out manner until we reach out return(0) logic in the int main(void) function in our first stack frame.

If you don’t have a terminating case for the recursive example above, the stack will continue to grow in size adding additional stack frames on-top of each other, moving the stack pointer upward on each call, against the heap, which will be explained in the next section. In a recursive function , if there is no valid terminating condition, the stack will grow until you’ve completed consumed all the memory that’s been allocated for your program by the operating system. When the stack pointer exceeds the stack bound, you have a condition called stack overflow. Bad things happen when you have a stack overflow.

Let’s first refer back to the other four segments of your application’s memory which were the uninitialized and initialized data segments, text segment and stack segment. These four segments have a constant memory size during compilation. The memory size for these four segments is predetermined by your operating system before compiling your programs. When software engineers write programs that consume large amounts of memory from a machine, they have to consider where and how much memory is being consumed in their application.

The max stack size is constant and predetermined before a program is compiled. At Holberton, we use a Linux Ubuntu/Trusty64 distributions. To find information about the stack size and other neat limits, type the command below into your terminal.

ulimit -a

Where ulimit is a function that gets and sets user limits and the -a flag lists all the current limits.

Stack size is 8.192MB of memory.

If the stack is limited in size and a program needs more memory for it to execute, where can a software engineer pull memory from for his/her application? This is where the heap comes into play.

What is the heap?


The heap is the segment of memory that is not set to a constant size before compilation and can be controlled dynamically by the programmer. Think of the heap as a “free pool” of memory you can use when running your application. The size of the heap for an application is determined by the physical constraints of your RAM (Random access memory) and is generally much larger in size than the stack.

We use memory from the heap when we don’t know how much space a data structure will take up in our program, when we need to allocate more memory than what’s available on the stack, or when we need to create variables that last the duration of our application. We can do that in the C programming language by using mallocrealloccalloc and/or free. Check out the example below.

Allocating 4000 bytes of memory to our program, then releasing it.

We allocate memory from the heap using the malloc() function. The argument we want to include in malloc is the amount of memory we want to allocate to our application, in bytes. Malloc returns a void pointer that is type casted into an integer pointer that now points to the first address in memory for our 4000 byte long memory. We can now store information in those memory addresses and do as we please to that information for the duration of our program or for the duration of our function because we have a pointer that references the first memory address from the newly allocated heap memory.

If you aren’t intentionally creating variables that last the duration of your application from the heap, you always want to release the memory back to the machine using the free() function. If you don’t release the memory using the free() function, you have memory that will persist throughout your program. If we do not release the memory from our program before terminating the application, our application has memory leaks. If your application has enough memory leaks, it can consume more memory than is physically available and can cause programs to crash. This is why we use a program called valgrindValgrind is easy to use and checks for memory leaks.

Valgrind being used. 4,000 bytes allocated. 0 bytes leaks

Another thing to consider while using the heap, the pointer variables created on the heap are accessible by any function, anywhere in your program, as long as the memory is still persistent and hasn’t been free.

How does understanding the stack and heap make you a better software engineer?


If you understand the advantages and disadvantages of using the stack vs the heap for your application, then it gives you a strategic advantage for creating scalable programs. You, the programmer, have to decide when to use memory from the stack vs heap based on each problem you are trying to solve.

If you have a variable like an array or struct that needs to be stored in a large block memory, needs to persist throughout the lifetime of your application and could change in size throughout the duration of your program, then you should allocate it from the heap.

If you need to create helper functions with variables that only persist within the lifetime of the function, then you should allocate memory from the stack. Memory from the stack is easier to keep track of because the memory is only locally available in the function call which does not persist after the function is completed and is managed by the CPU.

Photo credit: Gribble Lab

Questions, comments or concerns, feel free to comment below, follow me or find me on Twitter @ NTTL_LTTN.

References:


My Code School. (February 23rd, 2013). Pointers and dynamic memory — stack vs heap. . Retrieved from https://www.youtube.com/watch?v=_8-ht2AKyH4

Paul Gribble (2012). C Programming Boot Camp — 7. Memory: Stack vs Heap. [Blog post]. Retrieved from https://www.gribblelab.org/CBootCamp/7_Memory_Stack_vs_Heap.html#orgheadline1

GeeksforGeeks. Memory Layout of C Programs. [Blog post]. Retrieved from https://www.geeksforgeeks.org/memory-layout-of-c-program/

Sandra Henry-Stocker. (November 18th, 2012). NETWORK WORLD — Setting limits with ulimit. [Blog post]. Retrieved from https://www.networkworld.com/article/2693414/operating-systems/setting-limits-with-ulimit.html

Valgrind Developers (2000–2017). Valgrind. Retrieved from http://valgrind.org/

Die.net Linux Documentation. Retrieved from https://linux.die.net/

Print this item